Professional Documents
Culture Documents
Time Series
Time Series
Time Series
A time series is a sequence of measurements
over time, usually obtained at equally spaced
intervals such as Daily, Monthly, Quarterly,
Yearly.
Yearly
Useful for:
RK Jana
Trend (Tt)
Linear
Nonlinear
Estimation of Trend
Additive Model
Yt = Tt + Ct + St + It
Multiplicative Model
Yt = Tt Ct St It
Or, log(Yt) = log(Tt) + log(Ct) + log(St) + log(It)
9/2/2009
More About MA
Let et = (Yt Yt )
10
Example 2
Continued
Normal equations:
S 2
= 0,
a
S 2
=0
b
This implies:
Y = na + b t
t
tY = a t + b t
Year:
Prod:
11
9/2/2009
Continued
Continued
Prod Yt
t2
tYt
Trend
Series After
Elimination of
Trends
-6
Year
t(=year1997)
1994
-3
77
-231
83
1995
-2
88
-176
85
1996
-1
1
94
-94
94
87
1997
85
89
-4
1998
91
91
91
196
93
1999
98
2000
90
270
95
-5
Sum
623
28
56
--
--
Here n = 7.
From normal equations: a = 89, b = 2
Fitted least square straight line: Yt = 89 + 2t
Rate of growth per year: dYt / dt = b
Rate of growth per month:
(000 tons)
dYt / dt = b /12
For 2001, t = 4
T2001 = 89 + 2 4 = 97 (000 tons)
13
14
It is used when the time series data consists of seasonal & random
components.
It removes the random component & the resulting average consists
of seasonal components only.
Then the averages are converted to Seasonal Indices.
The Method:
1 12
xi , where xi is the average for i-th month
12 i =1
15
16
Continued
Seasonal Indices:
( SI )i =
Example 4
xi
100
x
Year
QI
QII
QIII
QIV
1998
1999
2000
2001
2002
120
105
106
104
89
125
120
110
112
105
90
125
105
102
90
105
100
80
85
100
( SI )i /100
17
18
9/2/2009
RatiotoTrend Method
Continued
Year
QI
QII
QIII
QIV
1998
1999
2000
2001
2002
120
105
106
104
89
125
120
110
112
105
90
125
105
102
90
105
100
80
85
100
Total
524
572
512
470
Average
104.8
114.4
102.4
94
( SI )i
100.87
110.10
98.56
90.47
Yt
T S I
100 = t t t 100
Tt
Tt
19
20
Example 5
Continued
Adding values of all quarters of a year, we obtain
yearly totals for each year & then fit a linear trend.
Year
Year
QI
QII
QIII
QIV
1998
1999
2000
2001
60
65
71
60
50
61
55
52
55
64
58
50
65
66
52
58
t 1998
t*t
1998
1999
2000
2001
Yt
230
256
236
220
0
1
2
3
0 Yt
256
472
660
0
1
4
9
Total
942
1388
14
Continued
Continued
22
2nd
Year
QI
QII
QIII
QIV
1998
1999
2000
2001
61.22
59.97
58.72
57.47
60.91
59.66
58.41
57.16
60.59
59.35
58.08
56.85
60.28
59.03
57.78
56.53
23
Year
QI
QII
QIII
QIV
1998
1999
2000
2001
98.00
108 38
108.38
120.91
104.40
82.09
102 25
102.25
94.16
90.97
90.76
107 84
107.84
99.83
87.95
107.82
111 80
111.80
89.99
102.59
Total
431.69
369.47
386.39
412.20
Average
107.92
92.37
96.60
103.05
Seasonal
Indices
107.93
92.38
96.61
103.08
24
9/2/2009
The Method
Ratiotomoving Average
Applicable if the data contain all four time
series components.
Select the period of moving average equal to
the period of seasonal variations (oscillatory
movements).
For monthly data, centered 12point moving average is
selected
For quarterly data, centered 4point moving average is
selected
Yt
T S Ct I t
100 = t t
= St I t''
MA
Tt Ct I t
25
26
Continued
Example 6
QI
QII
QIII
QIV
1998
1999
2000
2001
60
65
71
60
50
61
55
52
55
64
58
50
65
66
52
58
27
28
Continued
Year/
Quarter
1998
1999
2000
2001
Yt
I
II
III
IV
I
II
III
IV
I
II
III
IV
I
II
III
IV
60
50
55
65
65
61
64
66
71
55
58
52
60
52
50
58
4pt moving
average
(MA)
57.5
58.75
61.5
63.75
64.0
65.5
64.0
62.5
59.0
56.25
55.5
53.5
55.0
Continued
2pt cent.
MA
RatiotoMA
=100*Yt /MA
58.125
60.125
62.625
63 875
63.875
64.75
64.75
63.25
60.75
57.62
55.87
54.5
54.25
94.62
108.10
103.79
95 50
95.50
98.84
101.93
112.25
90.53
100.66
93.07
110.09
95.85
29
Year
QI
QII
QIII
QIV
1998
1999
2000
2001
103.79
112.25
110 09
110.09
95.50
90.53
95 85
95.85
94.62
98.84
100.66
108.10
101.93
93.07
Total
326.13
281.88
294.12
303.10
Average
108.71
93.96
98.04
101.03
Seasonal
Indices
108.24
93.55
97.62
100.59
30
9/2/2009
31
32
Continued
The Method
Observations: Y0 , Y1 , Y2 , ..
Time period: t
Forecasts: Ft , Ft1
t 1 , Ft2
t 2 , ..
Smoothing coefficient: , (0 < < 1)
Forecast errors: et = Yt Ft
Rewrite,
Ft = (Yt1) + (1 ) Ft1
= (Yt1) + (1 ) { (Yt2) + (1 ) Ft2}
= (Yt1) + (1 ) (Yt2) + (1 )2 Ft2
= .
Ft = (Yt1) + (1 ) (Yt2) + (1 )2 (Yt3) + ..
+ (1 )t1 (Y0) + (1 )t (F0)
33
34
Example: ES
Errors in ES
180
168
159
175
190
205
180
182
MSE =
1 n 1 2 1 n 1
et = n t =0 (Yt Ft )2
n t =0
(i)
MAD =
1 n 1
1 n 1
| et | = n t =0 | Yt Ft |
n t =0
36