LjungBoxPierceTest
determines the test statistic and p values for several lags for a residual series
LjungBoxPierceTest
determines the test statistic and p values for several lags for a residual seriesLjungBoxPierceTest(y, n.par = 0, maxlag = 48)
y
: the series of residuals, a vector or a time seriesn.par
: number of parameters which had been estimatedmaxlag
: maximal lag up to which the test statistic is computed, default is maxlag = 48BT matrix with columns: lags, degrees of freedom, test statistic, p-value
data(COFFEE) out <- arima(COFFEE,order=c(1,0,0)) BT <- LjungBoxPierceTest(out$residuals,1,20)
Useful links