[R-SIG-Finance] acf confidence intervals in ARMA

Brian G. Peterson brian at braverock.com
Fri Feb 8 16:29:19 CET 2008


Peter Carl wrote:
> On Friday 08 February 2008 8:05:20 am elton wang wrote:
>> I tried to understand the two formulas below by google
>> and books I have but have no success so far.
> 
> ?plot.acf
> Confidence limits assume a white noise input by default.
> 
>     "The confidence interval plotted in 'plot.acf' is based on an
>      _uncorrelated_ series and should be treated with appropriate
>      caution.  Using 'ci.type = "ma"' may be less potentially
>      misleading."

The ci.type of "white" uses a simple volatility model un the acf series 
to calculate the confidence intervals.  The "ma" or correlation model 
uses the volatility of the correlation of the lags of series to 
calculate the confidence intervals.

     with.ci <- ci > 0 && x$type != "covariance"
     with.ci.ma <- with.ci && ci.type == "ma" && x$type == "correlation"
     if(with.ci.ma && x$lag[1,1,1] != 0) {
         warning("can use ci.type=\"ma\" only if first lag is 0")
         with.ci.ma <- FALSE
     }
     clim0 <- if (with.ci) qnorm((1 + ci)/2)/sqrt(x$n.used) else c(0, 0)

Regards,

   - Brian



More information about the R-SIG-Finance mailing list