pcacfMat: Compute PAR autocovariance matrix

View source: R/pcstat.R

pcacfMatR Documentation

Compute PAR autocovariance matrix

Description

Compute PAR autocovariance matrix

Usage

pc.acf.parModel(parmodel, maxlag = NULL)

pcacfMat(parmodel)

Arguments

parmodel

PAR model, an object of class parModel.

maxlag

maximum lag

Details

pc.acf.parModel returns the autocovariances of a PAR model in season-lag form with maximum lag equal to maxlag. If maxlag is larger than the available precomputed autocovariances, they missing ones are computed using the Yule-Walker relations. Note that pc.acf.parModel assumes that there are enough precomputed autocovariances to use the Yule-Walker recursions directly.

TODO: pc.acf.parModel is tied to the old classes since it accesses their slots. Could be used as a template to streamline the method for autocovariances for class "PeriodicAutocovariance".

The season-lag form can be easily converted to other forms with the powerful indexing operator, see the examples and slMatrix-class.

pcacfMat is a convenience function for statistical inference. It creates a covariance matrix with dimension chosen automatically. This covariance matrix is such that the asymptotic covariance matrix of the estimated parameters can be obtained by dividing sub-blocks by innovation variances and inverting them. See, eq. (3.3) in the reference.

Value

for pcacfMat, a matrix

for pc.acf.parModel, an slMatrix

Author(s)

Georgi N. Boshnakov

References

\insertRef

McLeod1994diagnosticpcts

See Also

slMatrix-class

Examples

x <- arima.sim(list(ar = 0.9), n = 1000)
proba1 <- fitPM(c(3,2,2,2), x)

acfb <- pc.acf.parModel(proba1, maxlag = 8)
acfb[4:(-2), 4:(-2), type = "tt"]

pcacfMat(proba1)


GeoBosh/pcts documentation built on Dec. 8, 2023, 9:57 p.m.