VARMASIM Call

CALL VARMASIM( series, phi, theta, mu, sigma, n <*>, p <*>, q <*>, initial <*>, seed ) ;

The VARMASIM subroutine generates a VARMA(,) time series.

The input arguments to the VARMASIM subroutine are as follows:

phi

specifies a matrix that contains the autoregressive coefficient matrices, where is the number of the elements in the subset of the AR order and is the number of variables. You must specify either phi or theta.

theta

specifies a matrix that contains the moving average coefficient matrices, where is the number of the elements in the subset of the MA order. You must specify either phi or theta.

mu

specifies a (or ) mean vector of the series. If mu is not specified, a zero vector is used.

sigma

specifies a covariance matrix of the innovation series. If sigma is not specified, an identity matrix is used.

n

specifies the length of the series. If n is not specified, is used.

p

specifies the subset of the AR order. See the VARMACOV subroutine.

q

specifies the subset of the MA order. See the VARMACOV subroutine.

initial

specifies the initial values of random variables. If , then and all take the same value . If the initial option is not specified, the initial values are estimated for the stationary vector time series; the initial values are assumed as zero for the nonstationary vector time series.

seed

is a scalar that contains the random number seed. At the first execution of the subroutine, the seed variable is used as follows:

If seed > 0, the input seed is used for generating the series.

If seed = 0, the system clock is used to generate the seed.

If seed < 0, the value ()(seed) is used for generating the series.

If the seed is not supplied, the system clock is used to generate the seed.

On subsequent calls of the subroutine in the DO loop like environment the seed variable is used as follows: If seed > 0, the seed remains unchanged. In other cases, after each execution of the subroutine, the current seed is updated internally.

The VARMASIM subroutine returns the following value:

series

is an matrix that contains the generated VARMA() time series. When either the initial option is specified or zero initial values are used, these initial values are not included in series.

Consider the following bivariate () stationary VARMA(1,1) time series:

     
     

To generate this series, you can use the following statements:

  phi  = { 1.2 -0.5, 0.6 0.3 };
  theta= {-0.6  0.3, 0.3 0.6 };
  mu   = { 10, 20 };
  sigma= { 1.0  0.5, 0.5 1.25};
  call varmasim(yt, phi, theta, mu, sigma, 100);

Consider a bivariate () nonstationary VARMA(1,1) time series with the same , , and in the previous example and the following AR coefficient:

     

To generate this series, you can use the following statements:

  phi  = { 1.0 0.0, 0.0 0.3 };
  call varmasim(yt, phi, theta, mu, sigma, 100) initial=3;