portman.Q: Ljung-Box test for whiteness in a time series.

Description Usage Arguments Details Value References Examples

Description

portman.Q uses the cummulative ACF to test for whiteness of a time series.

Usage

1
portman.Q(x, K)

Arguments

x

A time series (vector without missing values).

K

the maximum lag of the ACF to be used in the test.

Details

This is the Ljung-Box version of the the Portemanteau test for whiteness (Tong 1990). It may in particular be usefull to test for whiteness in the residuals from time series models.

Value

A vector is returned consisting of the asymtpotic chi-square value, the associated d.f. and asymptotic p.val for the test of whiteness.

References

Tong, H. (1990) Non-linear time series : a dynamical system approach. Clarendon Press, Oxford.

Examples

1
2
3
4
5
6
   data(plodia)

   portman.Q(sqrt(plodia), K = 10) 

   fit <- ar(sqrt(plodia)) 
   portman.Q(na.omit(fit$resid), K = 10) 

nlts documentation built on May 1, 2019, 8:44 p.m.

Related to portman.Q in nlts...