Components of a time series
Trend (T) Long term growth (or decline)
Seasonal (S) Stable pattern of change that appears annually (or weekly) and repeats itself year after year
Cyclical (C) Wavelike fluctuations or cycles of more than one year’s duration
Irregular (I) Unpredictable or random fluctuations
Decomposition models
Additive model Y t
= T t
+ S t
+ C t
+ I t
Multiplicative model Y t
= T t
x S t
x C t
x I t
Trend
Linear trend T
ˆ t
b
0
+ b
1
t
Quadratic trend T
ˆ t
b
0
+ b
1
t + b
2
t
2
Create a column of t
2
. Then, run Regression with the two columns, t and t
2
as range of X-values.
Exponential trend T
ˆ t
b
0 b
1 t
Taking natural logarithm for both sides,
Ln( T
ˆ
) = Ln(b
0
) + Ln(b
1
) t i.e. Ln( T
ˆ
) = b
0
’
+ b
1
’
t
Create a column of Ln(Y). Then run Regression with the column of Ln(Y) as the range of Y-values and the column of t-values as the range of X-values.
The resulting intercept is b
0
’
and slope is b
1
’
. Then, b
0
e b
'
0 and b
1
e b
'
1
Seasonality (Ratio-to-moving-average method)
Step 1 Staring at the beginning of the series, compute moving total of 1 full seasonal cycle
(12 months for monthly data, 4 quarters for quarterly data, 5,6, or 7 days for weekly
Step 2
Step 3 data) Place the total at the center.
In case of even number of time periods compute a two-year moving total so that subsequent averages are centered rather than between time periods.
Find the average from the moving total (For odd number of periods per seasonal
Step 4
Step 5
Step 6 cycle divide by the number of seasons. For even number of periods per seasonal cycle divide by the 2 x the number of seasons (for monthly seasons divide by 24, for quarterly seasons divide by 8)
Compute seasonal ratio by dividing actual value by the average calculated in step 3.
Group the seasonal ratios for each season and determine the median ratio for each season.
Standardize the ratios such that the sum of the ratios is equal to the number of seasons. Standardized ratios are called Seasonal Indices.
Seasonally adjusted data
Additive model Y t
– S t
= T t
– I t
Multiplicative model
Y t
T t
I t
S t
Cyclical variation for Multiplicative model (C t
)
Step 1 C t
I t
Y t
T t
S t
C t
= Moving average of the ratios found in Step 1 (Use 5, or 7, or 9 periods) Step 2
Irregular variation for Multiplicative model (I t
)
It =
C t
I t
C t