ARMACOV Call
computes an autocovariance sequence for an ARMA model
- CALL ARMACOV( auto, cross, convol, phi, theta,
num);
The inputs to the ARMACOV subroutine are as follows:
- phi
- refers to a 1 ×(p+1) matrix
containing the autoregressive parameters.
The first element is assumed to have the value 1.
- theta
- refers to a 1 ×(q+1) matrix
containing the moving-average parameters.
The first element is assumed to have the value 1.
- num
- refers to a scalar containing n, the number of
autocovariances to be computed, which must be a positive number.
The ARMACOV subroutine returns the following values:
- auto
- specifies a variable to contain the returned 1 ×n
matrix containing the autocovariances of the specified ARMA
model, assuming unit variance for the innovation sequence.
- cross
- specifies a variable to contain the returned
1 ×(q+1) matrix containing the covariances of the
moving-average term with lagged values of the process.
- convol
- specifies a variable to contain the returned
1 ×(q+1) matrix containing the
autocovariance sequence of the moving-average term.
The ARMACOV subroutine computes the autocovariance
sequence that corresponds to a given autoregressive
moving-average (ARMA) time-series model.
An arbitrary number of terms in the sequence can be requested.
Two related covariance sequences are also returned.
The model notation for the ARMACOV
and ARMALIK subroutines is the same.
The ARMA(p,q) model is denoted
with .The notation is the same as that of Box and Jenkins
(1976) except that the model parameters are opposite in sign.
The innovations satisfy and
if k=0, and are zero otherwise.
The formula for the kth element
of the convol argument is
for k = 1,2, ... ,q+1.
The formula for the kth element of the cross argument is
for k = 1,2, ... ,q+1, where
is the ith impulse response value.
The sequence, if desired, can
be computed with the RATIO function.
It can be shown that is the same as
, which is used by Box and
Jenkins (1976, p. 75) in their formulation of the autocovariances.
The kth autocovariance, denoted and
returned as the k+1 element of the auto argument
(k = 0,1, ... ,n-1), is defined implicitly for k>0 by
where is the kth element of the cross argument.
See Box and Jenkins (1976) or McLeod (1975) for more information.
To compute the autocovariance function
at lags zero through four for the model
-
yt= 0.5yt-1 + et + 0.8et-1
use the following statements:
proc iml;
/* an arma(1,1) model */
phi ={1 -0.5};
theta={1 0.8};
call armacov(auto,cross,convol,phi,theta,5);
print auto,,cross convol;
The result is
AUTO
3.2533333 2.4266667 1.2133333 0.6066667 0.3033333
CROSS CONVOL
2.04 0.8 1.64 0.8
Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.