The theoretical autocovariance function of an ARMA(p,q) with unit
variance is computed. This algorithm has many applications.
In this package it is used for the computation of the information
matrix, in simulating p initial starting values for AR
simulations and in the computation of the exact mle for the mean.
The built-in R function ARMAacf could also be used but it is quite
complicated and apart from the source code, the precise algorithm
used is not described. The only reference given for ARMAacf is the
Brockwell and Davis (1991) but this text does not give any detailed
exact algorithm for the general case.
Another advantage of TacvfARMA over ARMAacf is that it will be easier
for to translate and implement this algorithm in other computing
environments such as MatLab etc.
Value
vector of length lag.max+1 containing the autocovariances is returned
Author(s)
A.I. McLeod
References
McLeod, A.I. (1975),
Derivation of the theoretical autocorrelation function of autoregressive
moving-average time series,
Applied Statistics 24, 255-256.
See Also
ARMAacf,
InformationMatrixARMA
Examples
#calculate and plot the autocorrelations from an ARMA(1,1) model
# with parameters phi=0.9 and theta=0.5
g<-TacvfARMA(0.9,0.5,20)
AcfPlot(g/g[1], LagZeroQ=FALSE)
Results
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(FitARMA)
Loading required package: FitAR
Loading required package: lattice
Loading required package: leaps
Loading required package: ltsa
Loading required package: bestglm
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/FitARMA/TacvfARMA.Rd_%03d_medium.png", width=480, height=480)
> ### Name: TacvfARMA
> ### Title: Theoretical Autocovariance Function of ARMA
> ### Aliases: TacvfARMA
> ### Keywords: ts
>
> ### ** Examples
>
> #calculate and plot the autocorrelations from an ARMA(1,1) model
> # with parameters phi=0.9 and theta=0.5
> g<-TacvfARMA(0.9,0.5,20)
> AcfPlot(g/g[1], LagZeroQ=FALSE)
>
>
>
>
>
> dev.off()
null device
1
>