[R] Fixed parameters in an AR (or arima) model

Henning Rust hrust at pik-potsdam.de
Wed Jan 14 16:15:47 CET 2004


Hi,
arima expects an order 4 model by specifying order=c(4,0,0). It looks 
like you want to fit an order 6 model with parameters 2 and 3 fixed to 
0. Try order=c(6,0,0) and fixed=c(NA,0,0,NA,NA,NA,NA), the last NA is 
for the intercept.
Henning


Jenný Brynjarsdóttir wrote:
> Hello
> 
> I want to fit an AR model were two of the coefficients are fixed to zero
> (the second and third ar-coefficients).
> 
> I used the "arima" function with the "fixed" argument but the ar3
> coefficient is not set to zero:
> 
> ==============================================
> 
>>arima(Y, order=c(4,0,0), xreg=1:23, fixed=c(NA,0,0,NA,NA,NA))
> 
> 
> Call:
> arima(x = Y, order = c(4, 0, 0), xreg = 1:23, fixed = c(NA, 0, 0, NA, NA,
> NA))
> 
> Coefficients:
>          ar1  ar2     ar3      ar4  intercept     1:23
>        0.5370    0  0.4338  -0.8078     5.2991  -0.0421
> s.e.  0.0735    0  0.0000   0.1096     0.1081   0.0079
> 
> sigma^2 estimated as 0.02665:  log likelihood = 6.77,  aic = -3.54
> ===============================================
> 
> Why?
> 
> Thanks,
> Jenný Brynjarsdóttir
> 
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
> 

-- 
Henning Rust
Potsdam Institute for Climate Impact Research
Dept. Integrated Systems Analysis
Tel.: #49/331/288-2596	
Fax.: #49/331/288-2640
PGP : pgp.mit.edu

Please avoid sending me Word or PowerPoint attachments,
send plain text or PDF instead.
See http://www.fsf.org/philosophy/no-word-attachments.html




More information about the R-help mailing list