Calcite | Level 5

## PROC x12 for Seasonal Month Regression Coefficient

Hello,

I'm trying to use PROC X12 to measure the effect of different calendar months on used vehicle prices.  Basically, I just want a coefficient that I can apply to a baseline price forecast (which is generated by OLS regression), that will adjust the baseline forecast up or down depending on what month it is.  For instance - "All things equal, used vehicle prices are 20% higher in March, so therefore if X(March) = 1, then B(March) = 1.2 and the baseline forecast would be increased by 20%".

Can this be done with Proc X12?  I know as an alternative I could create dummy variables for each calendar month and add those to the OLS regression to capture the same effect, but I'm wanting to try a different approach.  There are no time-series elements in my data (all observations are unique and uncorrelated - they are vehicles that were sold at auction), so I don't need any of the ARIMA functionality within X12.

Thanks,

2 REPLIES 2
SAS Employee

## Re: PROC x12 for Seasonal Month Regression Coefficient

I'm not exactly sure what you are looking for, but let me provide some info and see if this helps.

X13 (X12) has predefined regressors and also events can be used. You can use an ARIMA (0 0 0)(0 0 0) model. Parameters for regressors can be estimated. The event dummies can be output. You will need at least 3 years of data, but I know that sometimes people achieve this by repeating the same year 3 times.

Try the following code that uses several strategies including trading day regression, X13 predefined dummies and monthly dummies. (Note that the last term is usually derived to avoid singularity.) There are more options than I show, for instance trigonometric seasonal dummies and other trading day effects.

Also look for  "Regression Model Parameter Estimates" in the lst file. The parameter estimates can be output to a data set using "ods output RegParameterEstimates=<dataset name>".

``````proc x13 data=sashelp.air date=date;
regression predefined=TD;
estimate;
output out=TDreg A1 A6 B1;
run;

proc print data=TDreg;
run;

proc x13 data=sashelp.air date=date;
regression predefined=seasonal;
estimate;
output out=Seasonalreg A1 B1;
run;

proc print data=Seasonalreg;
run;

proc x13 data=sashelp.air date=date;
event January February March April May June July August
September October November /
usertype=seasonal seasonal seasonal seasonal seasonal
seasonal seasonal seasonal seasonal seasonal
seasonal;
estimate;
output out=Monthsreg A1 A10 B1;
run;

proc print data=Monthsreg;
run;

/* 35 observations is not enough data */
proc x13 data=sashelp.air(obs=35) date=date;
regression predefined=seasonal;
estimate;
output out=Seasonalreg A1 B1;
run;
``````
SAS Employee

## Re: PROC x12 for Seasonal Month Regression Coefficient

If you want to estimate seasonal components, then you will need to include the X11 statement.
Discussion stats
• 2 replies
• 317 views
• 0 likes
• 2 in conversation