Hi,

I have been using this website (

http://www.stat.pitt.edu/stoffer/tsa2/Rissues.htmhttp://www.stat.pitt.edu/stoffer/tsa2/Rissues.htm ) to help me to fit ARIMA

models to my data. At the moment I have two possible methods to use.

Method 1

If I use

arima(ts.data, order=c(1,2,0), xreg=1:length(ts.data))

then the wrong value for the intercept/mean is given (checked on SPSS and

Minitab) and also, this is produced

In sqrt(diag(x$var.coef)) : NaNs produced

Which means that the t-values (for the coefficients) are NaNs, which in turn

means that the p-values are NaNs.

Although, using this method gives the correct forecast (using predict) and

enables ts.plot to show the forecast and 95% CI's.

Method 2

If I use

diff(diff(ts.dat))

and then apply an ARIMA(1,0,0) to it, then this gives the correct

coefficients but the forecasts are wrong (ie they are flat and do not follow

the trend).

Could anyone think of a way to get both the coefficients AND the forecasts

correct?

Thanks.

--

View this message in context:

http://www.nabble.com/Time-Series---ARIMA-differencing-problem-tp22353903p22353903.htmlSent from the R help mailing list archive at Nabble.com.

______________________________________________

[hidden email] mailing list

https://stat.ethz.ch/mailman/listinfo/r-helpPLEASE do read the posting guide

http://www.R-project.org/posting-guide.htmland provide commented, minimal, self-contained, reproducible code.