1
$\begingroup$

my professor says that if we see that there are NA values for the AR or MA terms(either the estimated values or the estimated se) in the R output for the arima models fitted using the arima() function, it is suggesting that our model is over fit. Is he right?

I figured out that if I allow the function for a slightly higher number of iterations allowed, we can get get rid of those NAs in estimates and be able to obtain the a model.

So it appears to me that it can be just a simple problem with the optimization rather than blame the model to be too complex and overfit.

$\endgroup$

1 Answer 1

1
$\begingroup$

He might refer to a situation like the following one, where I generate a trajectory of length $n=20$ for an $AR(1)$ process, but fit a complex and overfitting $ARIMA(8,9)$ model that has almost as many parameters as data points, which creates NAs.

> n <- 20
> arima.sim(list(ar=.5),n)
Time Series:
Start = 1 
End = 20 
Frequency = 1 
 [1]  1.31055599  1.00629714  1.77500865  1.33925176  1.53007733 -1.77301333 -2.05737682 -3.64929708 -2.50377420  0.04239328  0.60926584
[12]  0.65004994 -1.90275516 -0.71533665  1.68576490  0.15163504  0.10553876 -0.17432651  0.57484940  0.21879489
> arima(x,c(8,0,9))

Call:
arima(x = x, order = c(8, 0, 9))

Coefficients:
          ar1     ar2     ar3     ar4      ar5      ar6     ar7      ar8     ma1      ma2      ma3      ma4     ma5     ma6      ma7     ma8
      -0.1135  0.0412  0.2174  0.5372  -0.1091  -0.3093  0.0316  -0.5688  0.1141  -0.0150  -0.2202  -0.5838  0.1465  0.3096  -0.0186  0.5180
s.e.      NaN  0.1695     NaN     NaN   0.1977   0.1391     NaN   0.1938     NaN   0.1741      NaN      NaN  0.2031  0.1554      NaN  0.1996
          ma9  intercept
      -0.0326     1.0031
s.e.   0.0213     0.0308

sigma^2 estimated as 1.036:  log likelihood = -1436.78,  aic = 2911.55
Warning messages:
1: In arima(x, c(8, 0, 9)) :
  evtl. Konvergenzproblem: optim lieferte Kode = 1
2: In sqrt(diag(x$var.coef)) : NaNs produced
$\endgroup$
5
  • $\begingroup$ I guess in your case it is really overfit. However the data been given to us has more than 1000 observations, fit a AR(4,4) with default setting would cause NaNs in estimated standard error. By only increase maxit from 100 to 200 can solve the problem. How can he just conclude that AR(4,4) is overfit. Really confusing in our case. $\endgroup$
    – Ryan Zhang
    Mar 23, 2016 at 18:12
  • $\begingroup$ Ok. In any case, you should probably provide more detail about your problem. $\endgroup$ Mar 23, 2016 at 18:46
  • $\begingroup$ It could also be a numerical issue resulting from the arma process having common roots. $\endgroup$ Mar 23, 2016 at 18:51
  • $\begingroup$ Thank you, sorry that I wasn't clear about my situation, I should find a way to post the data and code in the first place. $\endgroup$
    – Ryan Zhang
    Mar 24, 2016 at 2:32
  • $\begingroup$ How did you increase the max number of iterations? $\endgroup$
    – Nonancourt
    Jan 22, 2018 at 13:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.