|
<< Click to Display Table of Contents >> X12A |
![]() ![]()
|
The X12A (X12-arima) performs seasonal adjustment on quarterly or monthly data. The component uses a well-known external component developed by the US Census Bureau, and is similar to the AREMOS command with the same name. (It is considered to add X13-arima-seats and Tramo-Seats in Gekko, perhaps via the JDemetra+ project).
x12a < period PARAM=... BANK=... > variables ;
period |
(Optional). If not stated, Gekko will use the global time period. |
variables |
Variables and/or list(s). Wildcards may be used. |
PARAM= |
(Optional). A text string containing parameter values for X12A. If a parameter string is not provided, Gekko will use 'save=(d10, d11, saa) mode=mult sigmalim=(1.50,2.50) seasonalma=msr force=totals' as default parameter. With the default parameter, if you are correcting the series y, the series y_saa is the result. |
BANK= |
(Optional). A databank name indicating where the timeseries are located. |
•If no period is given inside the <...> angle brackets, the global period is used (cf. TIME).
•If a variable without databank indication is not found in the first-position databank, Gekko will look for it in other open databanks if databank search is active (cf. MODE).
Gekko appends the save=(...) types with underscore in the timeseries names, for instance y_saa for the saa type.
You may try the following example:
reset; |
Result:

Note the parameter save = (d10, d11, saa). You can choose between c17, d10, d11, d12, d13 and saa. The last one is only available if force=totals is set as parameter. Normally, the _saa series is considered the output of X12A.
For much more information on X12-arima, see https://www.census.gov/ts/x12a/v03/x12adocV03.pdf from the US Census Bureau. See section 2.7 regarding program limits. It seems that there is a limit starting at around 60 years of data. For quarterly data, only up to 60 calendar years are supported. And for monthly data, only up to 59 years (708 months) are supported. To remedy this, you may split the period into overlapping sub-periods and use SPLICE to splice them.
Please note that all the parameters are located inside a text string.
If you need to inspect the results in more detail, please inspect the tempX12aFile... files in the temporary files folder (cf. the Gekko menu Help --> About...).
If you need more advanced seasonal correction, you may consider using the R interface (see R_RUN). R contains quite a lot of facilities for seasonal correction.
The example can be exactly reproduced in AREMOS with the following AREMOS command:
x12a y d10,d11,saa "mode=mult sigmalim=(1.50,2.50) seasonalma=msr force=totals print=alltables"; |