VARMAX Procedure

COINTEG Statement

  • COINTEG RANK=number <options> ;

The COINTEG statement fits the vector error correction model to the data, tests the restrictions of the long-run parameters and the adjustment parameters, and tests for weak exogeneity in the long-run parameters. The P= option in the MODEL statement specifies the autoregressive order of the VECM. Only one COINTEG statement is allowed.

The cointegrated system uses maximum likelihood estimation. If there are no moving average (MA) terms specified by the Q= option in the MODEL statement, no GARCH terms specified in the GARCH statement, and no general restrictions specified in the BOUND and RESTRICT statements, then PROC VARMAX applies the maximum likelihood analysis proposed by Johansen and Juselius (1990); Johansen (1995a, 1995b). Otherwise, the likelihood is maximized using an optimizer whose options can be specified in the NLOPTIONS statement.

The following statements fit a VECM(2):

proc varmax data=one;
   model y1-y3 / p=2;
   cointeg rank=1;
run;

To test restrictions on bold-italic alpha and bold-italic beta, you specify the J= option and the H= option, respectively. You specify the EXOGENEITY option in the COINTEG statement for tests of weak exogeneity in the long-run parameters.

The following example of the COINTEG statement specifies tests of restrictions on bold-italic alpha and bold-italic beta, along with tests of weak exogeneity:

proc varmax data=one;
   model y1-y3 / p=2;
   cointeg rank=1 h=(1 0, -1 0, 0 1)
           j=(1 0, 0 0, 0 1) exogeneity;
run;

You must specify the following option:

RANK=number

specifies the cointegration rank of the cointegrated system. The rank of cointegration should be greater than 0 and less than the number of dependent (endogenous) variables. If number is different from the value of the RANK= option specified in the ECM= option in the MODEL statement, the number specified here is used for the rank.

You can also specify the following options in the COINTEG statement:

ECTREND

specifies the restriction on the drift in the VECM. This option is used in the following cases:

  • There is no separate drift in the VECM, but a constant enters only through the error correction term. For example, for VECM(p),

    normal upper Delta bold y Subscript t Baseline equals bold-italic alpha left-parenthesis bold-italic beta prime comma bold-italic beta 0 right-parenthesis left-parenthesis bold y prime Subscript t minus 1 Baseline comma 1 right-parenthesis Superscript prime Baseline plus sigma-summation Underscript i equals 1 Overscript p minus 1 Endscripts normal upper Phi Subscript i Superscript asterisk Baseline normal upper Delta bold y Subscript t minus i Baseline plus bold-italic epsilon Subscript t

    An example of the ECTREND option follows:

    model y1 y2 / p=2;
    cointeg rank=1 ectrend;
    
  • There is a separate drift and no separate linear trend in the VECM, but a linear trend enters only through the error correction term. For example, for VECM(p),

    normal upper Delta bold y Subscript t Baseline equals bold-italic alpha left-parenthesis bold-italic beta prime comma bold-italic beta 1 right-parenthesis left-parenthesis bold y prime Subscript t minus 1 Baseline comma t right-parenthesis Superscript prime Baseline plus sigma-summation Underscript i equals 1 Overscript p minus 1 Endscripts normal upper Phi Subscript i Superscript asterisk Baseline normal upper Delta bold y Subscript t minus i Baseline plus bold-italic delta 0 plus bold-italic epsilon Subscript t

    An example of the ECTREND option with the TREND= option follows:

    model y1 y2 / p=2 trend=linear;
    cointeg rank=1 ectrend;
    

If you specify both this option and the NSEASON option in the MODEL statement, then the NSEASON option is ignored. If you specify the NOINT option in the MODEL statement, then this option is ignored.

EXOGENEITY

formulates the likelihood ratio tests for testing weak exogeneity in the long-run parameters. The null hypothesis is that one variable is weakly exogenous for the others.

H=(matrix)

specifies the restrictions bold upper H on the k times r or left-parenthesis k plus 1 right-parenthesis times r cointegrated coefficient matrix bold-italic beta overTilde such that bold-italic beta overTilde equals bold upper H bold-italic phi, where bold upper H is known and bold-italic phi is unknown. If you do not specify the ECTREND option, then the cointegrated coefficient matrix bold-italic beta overTilde is the cointegrating matrix bold-italic beta and the bold upper H matrix has dimension k times m. If you specify the ECTREND option, then the cointegrated coefficient matrix bold-italic beta overTilde is the cointegrating matrix bold-italic beta stacked with the coefficient row vector bold-italic beta 0 or bold-italic beta 1 for the constant or linear trend in the error correction term, and the bold upper H matrix has dimension left-parenthesis k plus 1 right-parenthesis times m. Here k is the number of dependent variables and m is r less-than-or-equal-to m less-than k, where r is defined in the RANK=r option.

For example, consider a VECM(2) with rank equal to 1 on four dependent variables. Then, bold-italic beta equals left-parenthesis beta 11 comma beta 21 comma beta 31 comma beta 41 right-parenthesis prime. To test the null hypothesis beta 11 plus beta 21 equals 0 (that is, bold upper H prime Subscript up-tack Baseline bold-italic beta equals 0, where bold upper H Subscript up-tack Baseline equals left-parenthesis 1 negative 1 0 0 right-parenthesis prime), you can use the following statements to specify the restriction matrix bold upper H:

model y1-y4 / p=2;
cointeg rank=1 h=(1 0 0, -1 0 0, 0 1 0, 0 0 1);

Here the dimension of matrix bold upper H is 4 times 3 because k equals 4 and m equals 3, and each row of the matrix bold upper H is separated by commas. Note that bold upper H prime Subscript up-tack Baseline bold upper H equals 0; that is, the bold upper H and bold upper H Subscript up-tack matrices are orthogonal.

When the series has no separate deterministic trend, and therefore you specify the ECTREND option, the constant term should be restricted by bold-italic alpha prime Subscript up-tack Baseline bold-italic delta equals 0. The matrix bold-italic alpha Subscript up-tack is a k times left-parenthesis k minus r right-parenthesis full-rank matrix orthogonal to bold-italic alpha, such that r a n k left-parenthesis bold-italic alpha Subscript up-tack Baseline right-parenthesis equals k minus r and bold-italic alpha prime Subscript up-tack Baseline bold-italic alpha equals 0. The bold-italic beta overTilde becomes left-parenthesis bold-italic beta prime comma bold-italic beta 0 right-parenthesis prime or bold-italic beta overTilde equals left-parenthesis beta 11 comma beta 21 comma beta 31 comma beta 41 comma beta 11 Superscript left-parenthesis 0 right-parenthesis Baseline right-parenthesis prime. As for the previous test of beta 11 plus beta 21 equals 0 (that is, bold upper H prime Subscript up-tack Baseline bold-italic beta overTilde equals 0, where bold upper H Subscript up-tack Baseline equals left-parenthesis 1 negative 1 0 0 0 right-parenthesis prime), you can specify the restriction matrix bold upper H as follows:

model y1-y4 / p=2;
cointeg rank=1 ectrend
   h=(1 0 0 0, -1 0 0 0, 0 1 0 0, 0 0 1 0, 0 0 0 1);

Because the dimension is changed in the bold upper H Subscript up-tack matrix, the dimension of bold upper H matrix has to be adjusted accordingly.

When the cointegrated system contains three dependent variables and the RANK=2 option is specified, the test of beta Subscript 1 j Baseline equals minus beta Subscript 2 j Baseline for j equals 1 comma 2 can be run with the following restriction matrix bold upper H, where bold upper H Subscript up-tack Baseline equals left-parenthesis 1 1 0 right-parenthesis prime and bold upper H prime Subscript up-tack Baseline bold-italic beta equals 0:

cointeg rank=2 h=(1 0, -1 0, 0 1);

There are many ways to achieve a matrix that is orthogonal to a particular matrix. The following statements illustrate how to obtain the orthogonal matrix through QR decomposition:

proc iml;
   /* For a given matrix H_dot, */
   H_dot = {1 1 0}`;
   /* get its QR decomposition, i.e., H_dot = QR. */
   call qr(Q, R, piv, lindep, H_dot);
   /* Then, the matrix orthogonal to H_dot
      can be extracted from Q. */
   H = Q[,ncol(H_dot)+1:nrow(H_dot)];
   /* Finally, normalize each column of H if necessary. */
   do i = 1 to ncol(H);
      k = 0;
      do j = nrow(H) to 1 by -1;
         if (H[j,i]^=0) then k=j;
      end;
      if (k=0) then
         print "Error: H is not full rank!";
      else
         do j = nrow(H) to 1 by -1;
            H[j,i] = H[j,i] / H[k,i];
         end;
   end;
   print "The given matrix is:";
   print H_dot;
   print "The matrix orthogonal to it is:";
   print H;
quit;
J=(matrix)

specifies the restrictions bold upper J on the k times r adjustment matrix bold-italic alpha such that bold-italic alpha equals bold upper J bold-italic psi, where bold upper J is known and bold-italic psi is unknown. The k times m matrix bold upper J is specified by using this option, where k is the number of dependent variables, m is r less-than-or-equal-to m less-than k, and r is defined in the RANK=r option.

For example, suppose the system contains four variables, the RANK=1 option is specified, and you want to test alpha Subscript j Baseline equals 0 for j equals 2 comma 3 comma 4 —that is, bold upper J prime Subscript up-tack Baseline bold-italic alpha equals 0, where

StartLayout 1st Row  upper J Subscript up-tack Baseline equals Start 4 By 3 Matrix 1st Row 1st Column 0 2nd Column 0 3rd Column 0 2nd Row 1st Column 1 2nd Column 0 3rd Column 0 3rd Row 1st Column 0 2nd Column 1 3rd Column 0 4th Row 1st Column 0 2nd Column 0 3rd Column 1 EndMatrix EndLayout

Then you can specify the restriction matrix bold upper J as follows:

cointeg rank=1 j=(1, 0, 0, 0);

Suppose the system contains three variables, the RANK=2 option is specified, and you want to test alpha Subscript 2 j Baseline equals 0 for j equals 1 comma 2—that is, bold upper J prime Subscript up-tack Baseline bold-italic alpha equals 0, where bold upper J Subscript up-tack Baseline equals left-parenthesis 0 1 0 right-parenthesis prime. Then you can specify the restriction matrix bold upper J as follows:

cointeg rank=2 j=(1 0, 0 0, 0 1);
NLC

specifies the nonlinear constraints that bold-italic alpha and bold-italic beta are full column rank. Although the constraints are required for a well-defined VECM, only the TECH=QUANEW and TECH=NMSIMP optimization methods in the NLOPTIONS statement support nonlinear constraints. The full-rank constraints are not imposed by default so that other optimization methods, such as TECH=CONGRA or TECH=TRUREG, can be tried. The NLC option works only when numerical optimization is used for estimating VECM (for example, when the BOUND, INITIAL, or RESTRICT statement is specified, or the VEC-ARMA or VEC-ARMA-GARCH model is estimated). That is, the NLC option is ignored if the closed-form solution of parameter estimates and maximum likelihood analysis, which is provided in Johansen and Juselius (1990) and Johansen (1995a, 1995b), can be applied.

NORMALIZE=variable

specifies a single dependent (endogenous) variable whose cointegrating vectors are normalized. If the variable is different from the variable specified in the COINTTEST=(JOHANSEN=) or ECM= option in the MODEL statement, the variable in this option is used. If this option is not specified, cointegrating vectors are not normalized.

If the EXOGENEITY, H=, J=, or NORMALIZE= option is specified, the BOUND, GARCH, INITIAL, and RESTRICT statements are all ignored, and the Q= option in the MODEL statement is also ignored.

Last updated: June 19, 2025