David Stoffer describes some challenges with R's output when fitting
ARIMA models for different orders (see Issue 2 at
http://www.stat.pitt.edu/stoffer/tsa2/Rissues.htm). R doesn't fit an
intercept in the model if there is any differencing. David describes a
workaround using the xreg parameter to force R to calculate an
intercept.

Assume I have a variable y and 3 explanatory variables a, b and c. 

No intercept would be produced for the model .... fit = arima(y,
order=c(1,1,0), xreg=c(a,b,c)) 

1. If I wish to force an intercept to be output is the following
correct?

intercept = 1:length(y) 
fit2 = arima(y, order=c(1,1,0), xreg=c(intercept, a, b, c)) 

2. If 1 is correct, is the following code equivalent?

data = ts.intersect(diff(y),intercept, a,b,c)
fit3 = arima(data[,1], order=c(1,0,0), xreg=[,c(2:5)]) 

3. If I fit 2 and find the intercept is not significant would it be
correct to use the following?

fit = arima(y, order=c(1,1,0), xreg=c(a,b,c)) 

Thanks for your help

Kind regards

Pete

This e-mail may contain confidential or proprietary information
belonging to the BP group and is intended only for the use of the
recipients named above.  If you are not the intended recipient, please
immediately notify the sender and either delete this email or return to
the sender immediately.  You may not review, copy or distribute this
email.  Within the bounds of law, this part of BP retains all emails and
IMs and may monitor them to ensure compliance with BP's internal
policies and for other legitimate business purposes.


        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to