I found this code online and I wanted to dissect it before programming something similar in SAS.
The problem is idenitfy seasonality in a time series. I want to understand the code line by line:
proc x12 data=sales date=date season=12; var unempl_rate *already log differenced; transform function=none; regression predefined=td; automdl maxorder=(1,1) print=unitroottest unitroottestmdl autochoicemdl best5model; estimate; x11; output out=out(obs=23) a1 d11 d18; run; proc print data=out(obs=23); title 'Output Variables Related to Trading Day Regression'; run;
- the first line just defined use the x12 procedure with data set called "sales" - monthly data, indexed by variable "date" and expect a seasonality in the data every 12 months.
- this line tells which variable to analyze.
- no transformation was necessary since a transformation was already done.
- this line confuses me a little, is "regression predifined=td" applied for adjustment/outliers/events?
5-7. do these lines mean to estimate the best ARIMA (linear) models on the residual? 8-onwards. For outputing results