Conference on Seasonality, Seasonal Adjustment and their implications for Short-Term Analysis and Forecasting 10-12 May 2006 Developing and Improving a Moving Regression Weekly Seasonal Adjustment Program Tom Evans, Jerry Fields, Stuart Scott
Developing and Improving a Moving Regression Weekly Seasonal Adjustment Program Tom Evans, Jerry Fields, Stuart Scott Bureau of Labor Statistics Washington, DC, USA
Outline • Background • The CATS Programs • RegMOVE • Future Work 2
Background • Standard seasonal adjustment programs such as X-12-ARIMA and TRAMO/SEATS are for monthly and quarterly data • Pierce, Grupe, and Cleveland (1984) have a deterministic approach to weekly seasonally adjustment using fixed regression with ARIMA errors 3
Background • Cleveland (1993) expands on the earlier approach by adding locally weighted regressions by year to allow for moving seasonal factors • Harvey, Koopman, and Riani (1997) propose a structural time series method with splines 4
Background • BLS uses a modified version of Cleveland’s locally weighted regression program • BLS seasonally adjusts weekly initial claims and continued claims from the Unemployment Insurance program 5
The Calendar • Gregorian calendar has a 400-year cycle • 97 leap years • 329 52-week years 71 53-week years • 53-week years occur every 5.634 years on average, ranging from 5-7 years apart 6
The CATS Programs • Pierce, Grupe, and Cleveland (1984) C alendar A djustment and T ime S eries (CATS-D) • y t = s 1t + p 1t + s 2t + p 2t + e t 7
The CATS Programs • CATS-D Seasonal Component ⎛ ⎞ π π k 2 ( ) 2 ( ) iY t iY t ∑ = + + ⎜ ⎟ sin cos w a b ⎜ ⎟ t i i N N ⎝ ⎠ = 1 i y y ⎛ ⎞ π π l 2 ( ) 2 ( ) iM t iM t ∑ + ⎜ sin cos ⎟ c d i i ⎝ ⎠ N N = 1 i m m 8
The CATS Programs • Projected Factors Method • Overall Deterministic Model ′ Δ − β = θ ( ) y x L e t t t 9
The CATS Programs • CATS-M Method (moving seasonality) 1) Fixed global regression w/o weights for y 2) Remove the trend, calendar, and outlier effects to make y* 3) Separate regressions for y* for each year with same seasonal model but different weights 10
The CATS Programs • No ARIMA model for error term • Slope and trend terms added to design matrix Overall Model: ′ Δ − β = y x e t t t 11
12 The CATS Programs X Wy ′ e 1 − + ) β X WX • Weighted regression X ′ = ( = y β ˆ
The CATS Programs • Weights are found using the model = + y x e t t t − − φ = (1 )(1 ) L L x a t t [ ] ⎡ − ⎤ = + Σ υ = 1 | E x y I y Wy ⎣ ⎦ x where υ = σ σ 2 2 , / e a 13
The CATS Programs • ν =10 and ν =24 are similar to 3x5 and 3x9 filters • Changing the value of φ affects how quickly the seasonal factors move • Neighboring years are more heavily weighted 14
The CATS Programs • Typically need a long series to estimate holidays or events • Challenging to properly specify holidays 15
The CATS Programs • Twelve events are built in the program • There are 10 holidays and 3 user-defined events for UI initial claims series • Examples of user-defined events are Xmas on Friday, July 4 th on Wednesday, and Xmas on Sunday in week 53 16
RegMOVE • The new program is called RegMOVE since they are moving regressions • RegMOVE is a SAS program that calls CATS-M to simplify execution and to integrate high-resolution graphics • Important to integrate diagnostics and graphs to speed up analysis 17
RegMOVE • New output files that are easily machine- readable • Basic documentation • Additional diagnostics: Ljung-Box at seasonal lags Bera-Jarque normality test P-values for components, coefficients and tests Differenced R 2 18
19 RegMOVE
20 RegMOVE
21 RegMOVE
22 RegMOVE
23 RegMOVE
24 RegMOVE
25 RegMOVE
RegMOVE Table 1: Global Fixed Regression Diagnostics RegMOVE ver 2.01 Execution at 13:05, 18-APR-2006 series: iclaims series begins: 1988 week: 05 series ends: 2005 week: 05 output file: anova.dat COMPONENT DoF SS MSS F p-value Holiday 13 5.7408 0.4416 208.6801 0.0000 Outliers 14 0.6662 0.0476 22.4855 0.0000 Seasonal 60 6.5367 0.1089 51.4827 0.0000 Linear trend 2 0.0001 0.0001 0.0278 0.9726 Model 89 13.3453 0.1499 70.8585 0.0000 Error 798 1.6887 0.0021 Total 887 15.0339 0.0169 R-Square= 88.77% Box-Ljung statistic (approx. chi-square) Lag Q p-value 52 261.8703 0.0000 104 398.6564 0.0000 26
RegMOVE Outlier estimates WK YEAR FACTOR STD. ERR. T p-value 40 1989 1.1819 0.0341 4.9071 0.0000 30 1992 1.3985 0.0340 9.8651 0.0000 30 1993 1.3369 0.0341 8.5235 0.0000 52 1993 0.8780 0.0345 -3.7721 0.0001 5 1994 1.1249 0.0340 3.4606 0.0003 3 1996 1.1737 0.0351 4.5618 0.0000 38 2001 1.1314 0.0442 2.7954 0.0027 39 2001 1.2863 0.0568 4.4354 0.0000 40 2001 1.1745 0.0623 2.5833 0.0050 41 2001 1.1738 0.0626 2.5594 0.0053 42 2001 1.1302 0.0576 2.1269 0.0169 43 2001 1.1136 0.0442 2.4328 0.0076 47 2001 1.1716 0.0393 4.0335 0.0000 48 2001 1.1736 0.0406 3.9422 0.0000 Holiday estimates HOLIDAY FACTOR STD. ERR. T p-value User 1.1065 0.0251 4.0368 0.0000 User 1.0479 0.0220 2.1301 0.0167 User 0.9185 0.0257 -3.3056 0.0005 New Years 1.0850 0.0103 7.8931 0.0000 MLK Day 0.8286 0.0169 -11.0996 0.0000 Presidential 0.9330 0.0166 -4.1875 0.0000 Easter 0.9539 0.0082 -5.7615 0.0000 Memorial Day 0.8947 0.0163 -6.8484 0.0000 4th of July 0.9544 0.0164 -2.8500 0.0022 Labor Day 0.8912 0.0166 -6.9222 0.0000 Columbus Day 0.9532 0.0178 -2.6927 0.0036 Veterans Day 0.8762 0.0166 -7.9629 0.0000 Thanksgiving 0.7996 0.0178 -12.5724 0.0000 Seasonal estimates TERM FACTOR STD. ERR. T p-value 1 0.3486 0.1822 1.9136 0.0280 27 2 1.7341 0.1823 9.5126 0.0000 etc.
RegMOVE Table 2: Global Fixed Regression Output RegMOVE ver 2.01 Execution at 11:47, 18-APR-2006 series: iclaims series begins: 1988 week: 05 series ends: 2005 week: 05 output file: global.dat OBSERVATION ESTIMATE RESIDUAL STD. ERR. T p-value [EFFECT FACTOR STD. ERR. T p-value] 1 395000. 395001. -0.0645 0.0128 -5.0332 0.0000 2 381000. 406394. -0.0025 0.0129 -0.1973 0.4218 3 335000. 358236. 0.0333 0.0129 2.5723 0.0051 4 316000. 326866. -0.0246 0.0180 -1.3646 0.0864 [Holiday 0.9330 0.0166 -4.1875 0.0000] 5 324000. 343474. -0.0411 0.0153 -2.6853 0.0037 6 312000. 344613. -0.0063 0.0124 -0.5080 0.3058 7 294000. 326789. -0.0145 0.0124 -1.1710 0.1210 8 276000. 311262. -0.0028 0.0125 -0.2200 0.4129 9 269000. 304204. 0.0002 0.0145 0.0114 0.4952 10 257000. 290585. 0.0255 0.0147 1.7313 0.0419 [Holiday 0.9539 0.0082 -5.7615 0.0000] 28
RegMOVE Table 3: Sine and Cosine Coefficients from Locally Weighted Regressions RegMOVE ver 2.01 Execution at 11:47, 18-APR-2006 series: iclaims series begins: 1988 week: 05 series ends: 2005 week: 05 output file: coefs.dat 1 1988 0.3010 1 1989 0.3283 1 1990 0.3502 1 1991 0.3732 1 1992 0.3843 1 1993 0.4029 1 1994 0.4119 1 1995 0.4196 1 1996 0.4175 1 1997 0.4036 1 1998 0.3851 1 1999 0.3604 1 2000 0.3257 1 2001 0.2905 1 2002 0.2703 1 2003 0.2615 1 2004 0.2465 2 1988 1.9176 2 1989 1.9252 29 2 1990 1.9308 etc.
Future Work • Additional diagnostics • Allow for square-root transformation • Possible code upgrades or rewrites • Improved documentation 30
Recommend
More recommend