Imposing restrictions on parameters in an autoregressive model using the AUTOREG procedure


You can use the RESTRICT statement to impose restrictions on parameters in the preceding MODEL statement in the AUTOREG procedure. Any number of RESTRICT statements can follow a MODEL statement. To specify more than one restriction in a single RESTRICT statement, separate them with commas. To impose restrictions on AR, GARCH, and HETERO parameters in the RESTRICT statement, you must specify the GARCH= option. If you specify an AR, GARCH, or HETERO parameter in the RESTRICT statement and no GARCH= option is specified, an error occurs.

For example, these statements cause an error message to appear in the log.

model y = x / nlag=2;
restrict _A_1=0.2;


Here is the error that appears:

ERROR: The variable _A_1 was found in a TEST or RESTRICT statement, but it is not present in the model being optimized.


If you want to impose restrictions on AR or HETERO parameters, but your model does not have a GARCH effect, then you can specify the GARCH=(q=1) option and restrict the _AH_1 parameter to equal zero together with any other parameter restrictions that you want to impose. Specifying the GARCH=(q=1) option with the restriction that _AH_1=0 is equivalent to specifying the model with no GARCH effects. For example, if you want to impose the restriction that _A_1=0.2 in the AR(2) model specified above, then you can specify the following:

model y = x / nlag=2 GARCH=(q=1);
restrict _A_1=0.2, _AH_1=0;


Sometimes you might want to compute predicted values for the dependent variable in an AR model without GARCH effects using predetermined parameters, but you do not have a sufficient number of observations to obtain reliable estimates. Or you might want to evaluate how a given set of parameter estimates in an AR model predict the dependent variable by comparing the predicted values to the actual observed data. In these situations, you can specify the GARCH=(q=1) option in the MODEL statement, and use the RESTRICT statement to restrict the _AH_1 parameter to zero and all the AR model parameters to fixed values. You can use this approach to compute predicted values in the AR model provided that you have at least k+1 observations on both the dependent and independent variables in the beginning of the data set, where k is the total number of parameters in the model in which GARCH=(q=1) is specified. The following example illustrates this approach.

The following DATA step creates the data to be analyzed. The variable X contains the annual real GNP series from 1901 to 1973. The dependent variable in this analysis is the natural log of real GNP, Y. The independent variable in the model is the time trend variable, T. Suppose you assume an AR(2) error process for this data and you want to use parameter estimates already obtained by other studies to compute the predicted values up to year 1983. To have PROC AUTOREG produce predictions for years from 1974 to 1983, values of T are provided and the dependent variable, Y, is set to missing.

data gnp;
   input x @@;
   y = log(x);
   t = _n_;
   year = intnx('year', '01jan1901'd, _n_-1);
   format year year4.;
   label y = 'Real GNP'
         t = 'Time Trend';
   datalines;
137.87  139.13  146.10  144.21  155.04  172.97  175.61  161.22
180.93  185.98  191.90  201.51  203.38  195.96  193.63  208.19
211.43  244.33  228.99  214.22  199.94  229.54  254.09  256.39
276.03  291.81  293.27  296.22  315.69  285.52  263.46  227.04
222.13  239.09  260.04  295.54  310.16  296.75  319.83  344.16
400.40  461.80  531.66  569.13  560.17  478.28  470.39  489.74
492.24  534.57  579.17  600.63  623.46  615.64  657.37  671.72
683.57  680.88  721.72  737.01  756.59  800.29  832.20  875.96
929.00  984.62 1011.38 1058.06 1087.58 1085.58 1122.42 1185.92
1254.20     .       .       .       .       .       .       .
          .       .       .

The following PROC AUTOREG step specifies the regression model with the AR(2) error process. The NLAG=2 option together with GARCH=(q=1) specifies an AR(2)-ARCH(1) model. The RESTRICT statement fixes all parameters in the model at known values. The added restriction that _AH_1=0 ensures that the AR(2)-ARCH(1) model specified is equivalent to the AR(2) model without the ARCH effects. The OUTPUT statement saves the predicted values, PY, of dependent variable in output data set B.

proc autoreg data=gnp;
   model y = t / nlag=2 garch=(q=1);
   restrict intercept=4.82694, t=0.029974, _A_1=-1.21087, _A_2=0.38254, _AH_1=0;
   output out=b p=py;
   run;


The following step displays the first ten original and predicted values in the data set B. The last ten observations contain the predictions for years 1974 through 1983.

proc print data=b noobs;
   where t<11 or t>73;
   id year;

  title "Predictions from prespecified AR(2) model";
   run;

 

The results are shown below.

 

Predictions from prespecified AR(2) model

 

yearpyxyt
19014.85691137.874.926311
19024.94767139.134.935412
19034.94907146.104.984293
19045.00992144.214.971274
19054.98060155.045.043685
19065.07841172.975.153126
19075.18837175.615.168277
19085.16999161.225.082778
19095.06582180.935.198119
19105.24333185.985.2256410
19747.15371..74
19757.16100..75
19767.16753..76
19777.17780..77
19787.19287..78
19797.21235..79
19807.23531..80
19817.26081..81
19827.28804..82
19837.31641..83