Example 32.7 MDLINFOIN= and MDLINFOOUT= Data Sets
This example illustrates the use of MDLINFOIN= and MDLINFOOUT= data sets. Using the data set shown, PROC X12 step identifies the model with outliers as displayed in Output 32.7.1. Output 32.7.2 shows the data set that represents the chosen model.
data b1;
input y @@;
datalines;
112 118 132 129
121 135 148 148
136 119 104 118
115 126 141 135
125 149 270 170
158 133 114 140
;
title 'Model Identification Output to MDLINFOOUT= Data Set';
proc x12 data=b1 start='1980q1' interval=qtr MdlInfoOut=mdl;
automdl;
outlier;
run ;
proc print data=mdl;
run;
Output 32.7.1
Displayed Model Identification with Outliers
1980Q1 |
1985Q4 |
24 |
Add One |
3.419415 |
3.419415 |
Automatically Identified |
AO 1984Q3 |
Est |
102.36589 |
5.96584 |
17.16 |
<.0001 |
0.40892 |
0.20213 |
2.02 |
0.0554 |
-0.53710 |
0.20975 |
-2.56 |
0.0178 |
Output 32.7.2
PROC X12 MDLINFOOUT= Data Set Model with Outlier Detection
y |
REG |
EVENT |
SCALE |
AO |
AO01JUL1984D |
. |
. |
. |
. |
0 |
102.366 |
5.96584 |
17.1587 |
0.000000 |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
DIF |
y |
. |
. |
1 |
. |
. |
. |
. |
. |
. |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
AR |
y |
. |
1 |
1 |
. |
0 |
0.409 |
0.20213 |
2.0231 |
0.055385 |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
AR |
y |
. |
1 |
2 |
. |
0 |
-0.537 |
0.20975 |
-2.5606 |
0.017830 |
. |
|
|
Suppose that after examining the output from the preceding example, you decide that an Easter regressor should be added to the model. The following statements create a data set with the model identified above and adds a U.S. Census Bureau Predefined Easter(25) regression. The new model data set to be used as input in the MDLINFOIN= option is displayed in the data set shown in Output 32.7.3.
data pluseaster;
_NAME_ = 'y';
_MODELTYPE_ = 'REG';
_MODELPART_ = 'PREDEFINED';
_COMPONENT_ = 'SCALE';
_PARMTYPE_ = 'EASTER';
_DSVAR_ = 'EASTER';
_VALUE_ = 25;
run;
data mdlpluseaster;
set mdl;
run;
proc append base=mdlpluseaster data=pluseaster force;
run;
proc print data=mdlpluseaster;
run;
Output 32.7.3
MDLINFOIN= Data Set Model with Easter(25) Regression Added
y |
REG |
EVENT |
SCALE |
AO |
AO01JUL1984D |
. |
. |
. |
. |
0 |
102.366 |
5.96584 |
17.1587 |
0.000000 |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
DIF |
y |
. |
. |
1 |
. |
. |
. |
. |
. |
. |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
AR |
y |
. |
1 |
1 |
. |
0 |
0.409 |
0.20213 |
2.0231 |
0.055385 |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
AR |
y |
. |
1 |
2 |
. |
0 |
-0.537 |
0.20975 |
-2.5606 |
0.017830 |
. |
|
|
y |
REG |
PREDEFINED |
SCALE |
EASTER |
EASTER |
25 |
. |
. |
. |
. |
. |
. |
. |
. |
. |
|
|
The following statement estimate the regression and ARIMA parameters by using the model described in the new data set mdlpluseaster. The results of estimating the new model are shown in Output 32.7.4.
proc x12 data=b1 start='1980q1' interval=qtr
MdlInfoIn=mdlpluseaster MdlInfoOut=mdl2;
estimate;
run;
Output 32.7.4
Estimate Model with Added Easter(25) Regression
Easter |
Easter[25] |
Est |
6.15738 |
4.89162 |
1.26 |
0.2219 |
User Defined |
AO01JUL1984D |
Est |
105.29433 |
6.15636 |
17.10 |
<.0001 |
0.44376 |
0.20739 |
2.14 |
0.0443 |
-0.54050 |
0.21656 |
-2.50 |
0.0210 |
The new model estimation results are displayed in the data set mdl2 shown in Output 32.7.5.
proc print data=mdl2;
run;
Output 32.7.5
MDLINFOOUT= Data Set, Estimation of Model with Easter(25) Regression Added
y |
REG |
PREDEFINED |
SCALE |
EASTER |
EASTER |
25 |
. |
. |
. |
0 |
6.157 |
4.89162 |
1.2588 |
0.22193 |
. |
|
|
y |
REG |
EVENT |
SCALE |
AO |
AO01JUL1984D |
. |
. |
. |
. |
0 |
105.294 |
6.15636 |
17.1033 |
0.00000 |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
DIF |
y |
. |
. |
1 |
. |
. |
. |
. |
. |
. |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
AR |
y |
. |
1 |
1 |
. |
0 |
0.444 |
0.20739 |
2.1397 |
0.04428 |
. |
|
|
y |
ARIMA |
FORECAST |
NONSEASONAL |
AR |
y |
. |
1 |
2 |
. |
0 |
-0.541 |
0.21656 |
-2.4959 |
0.02096 |
. |
|
|
Copyright
© 2008 by SAS Institute Inc., Cary, NC, USA. All
rights reserved.