On Mon, 19 Jul 2010, Skipper Seabold wrote:
I was playing around and fitting an AR(2) model using the yearly
sunspots data provided by R data(sunspots), actually with more years
than in the R default dataset, and I was curious as to how the roots
of the AR coefficients are computed in gretl?
When I run
arima 2 0 0 ; SUNACTIVITY --conditional
I get a constant and phi_1 = 1.39181 and phi_2 = -.690287
IIUC, the roots to check for stability should be the solution to the
characteristic polynomial, which is in this case, X^2 - 1.39181 * X +
.690287. Using MATLAB's (or NumPy's) roots function, I find that the
roots of this equation are both
0.69590262389467661+0.45387935182766354j
But gretl says they are both 1.0081-.6575j, which is not a root of the
above. Am I misunderstanding something? If so, could someone point
to a reference?
The roots in such a model are the solutions to
1 - phi_1 L - phi_2 L^2 = 0
Using the coefficients you report we get the following from
gretl's polroots function:
? m = { 1, -1.39181, 0.690287 }
Generated matrix m
? eval polroots(m)
1.0081 -0.65752
1.0081 0.65752
Allin Cottrell