预测:: checkresiduals和Box.test

时间:2018-03-06 23:31:36

标签: testing time-series forecasting arima

我试图使用外生回归量拟合ar模型,特别是季节性假人和AR(3)错误的趋势。为此,我使用以下代码:

modelo<-Arima(log.licor, order = c(3,0,0), xreg = tend_esta, include.mean = F)

没有任何意思,因为我没有留下任何季节性假人退出回归。

的结果
forecast::checkresiduals(modelo, test = "LB")

是:

    Ljung-Box test
data:  Residuals from Regression with ARIMA(3,0,0) errors
Q* = 77.787, df = 7, p-value = 3.886e-14

Model df: 17.   Total lags used: 24

的结果
Box.test(residuals(modelo), type = "Ljung-Box")

    Box-Ljung test

data:  residuals(modelo)
X-squared = 1.3407, df = 1, p-value = 0.2469
我对这些论点做错了吗?每个结果的含义完全不同。

1 个答案:

答案 0 :(得分:0)

我有同样的问题。在lag中使用fitdfBox.test参数。因此,对于您的问题,请看预测版本中它怎么说“ Model df:17”和“ Total lags used:24”?试试Box.test版本中的那些。