Statistics 2 Lecture 9
Statistics 2 Lecture 9
12th Edition
Global Edition
Chapter 16
Time-Series Forecasting
Common Approaches
to Forecasting
Time Series
t re n d
Sales U pw a r d
Sales Sales
Time Time
Downward linear trend Upward nonlinear trend
Sales
Summer
Winter
Summer
Winter Spring Fall
Spring Fall
Time (Quarterly)
Copyright ©2012 Pearson Education Chap 16-10
Cyclical Component
Long-term wave-like patterns
Regularly occur but may vary in length
Often measured peak to peak or trough to
trough
1 Cycle
Sales
Year
Copyright ©2012 Pearson Education Chap 16-11
Irregular Component
Moving Averages
Calculate moving averages to get an overall
impression of the pattern of movement over time
Averages of consecutive time series values for a
chosen period of length L
Exponential Smoothing
A weighted moving average
Second average:
Y2 Y3 Y4 Y5 Y6
MA(5)
5
etc.
30
7 33
20
8 37
9 37 10
10 50 0
11 40 1 2 3 4 5 6 7 8 9 10 11
etc… etc… Year
30
trend 20
10
0
1 2 3 4 5 6 7 8 9 10 11
Year
E1 Y1
Ei WYi (1 W )Ei 1
For i = 2, 3, 4, …
where:
Ei = exponentially smoothed value for period i
Ei-1 = exponentially smoothed value already
computed for period i - 1
Yi = observed value in period i
W = weight (smoothing coefficient), 0 < W < 1
Copyright ©2012 Pearson Education Chap 16-22
Exponential Smoothing Example
Suppose we use weight W = 0.2
Time Forecast
Sales Exponentially Smoothed
Period from prior
(Yi) Value for this period (Ei)
(i) period (Ei-1)
E1 = Y 1
1 23 -- 23
since no
2 40 23.000 (.2)(40)+(.8)(23)=26.4 prior
3 25 26.400 (.2)(25)+(.8)(26.4)=26.12 information
4 27 26.120 (.2)(27)+(.8)(26.12)=26.296 exists
5 32 26.296 (.2)(32)+(.8)(26.296)=27.437
6 48 27.437 (.2)(48)+(.8)(27.437)=31.549 Ei
Fluctuations
have been 60
smoothed
50
40
NOTE: the Sales
30
smoothed value in
this case is 20
Ŷi1 Ei
30 4 27 26.12
20 Forecast
5 32 26.296
10
6 48 27.4368
0
1 2 3 4 5 6 7 8 9 10 7 33 31.54944
8 37 31.83955
Data Point
9 37 32.87164
10 50 33.69731
40 Accuracy Measures
MAPE 20.0118
Sales
MAD 7.1397
35 MSD 80.1601
30
25
20
1 2 3 4 5 6 7 8 9 10
Index
40
2008 4 70 30
20
2009 5 65 10
0
0 1 2 3 4 5 6
Year
Copyright ©2012 Pearson Education Chap 16-30
Linear Trend Forecasting (continued)
40
2009 5 65 30
2010 6 ?? 20
10
0
0 1 2 3 4 5 6
Year
Copyright ©2012 Pearson Education Chap 16-31
Nonlinear Trend Forecasting
A nonlinear regression model can be used when
the time series exhibits a nonlinear trend
Quadratic form is one type of a nonlinear model:
2
Yi 0 1Xi 2 X i
i
Interpretation:
(β̂1 1) 100% is the estimated annual compound
growth rate (in %)
[(Y3 Y2 ) ( Y2 Y1 )] [(Y4 Y3 ) ( Y3 Y2 )]
[(Yn Yn-1 ) ( Yn-1 Yn-2 )]
Year Units
02 4
03 3
04 2
05 3
06 2
07 2
08 4
09 6
0 0
T T
Random errors Cyclical effects not accounted for
e e
0 0
T T
Trend not accounted for Seasonal effects not accounted for
Copyright ©2012 Pearson Education Chap 16-43
Measuring Errors
Choose the model that gives the smallest
measuring errors
Sum of squared errors Mean Absolute Deviation
(SSE) (MAD)
n n
SSE (Yi Ŷi ) 2
Y Ŷ
i i
i1
MAD i1
n
Sensitive to outliers
Less sensitive to extreme
observations
Value: Interpretation:
β̂0 2691.53 Unadjusted trend value for first quarter of first year
β̂1 1.040 4.0% = estimated quarterly compound growth rate
Online Topic
Index Numbers
Pi
Ii 100
Pbase
where
Ii = index number for year i
Pi = price for year i
Pbase = price for the base year
Copyright ©2012 Pearson Education Chap 16-57
Index Numbers: Example
DCOVA
Airplane ticket prices from 1995 to 2003:
Index
Year Price (base year
= 2006)
2001 272 85.0
P2002 288
2002 288 90.0 I 2000 100 (100) 90
2003 295 92.2
P2006 320
2004 311 97.2
2005 322 100.6 Base Year:
2006 320 100.0
P2006 320
I 2006 100 (100) 100
2007 348 108.8 P2006 320
2008 366 114.4
2009 384 120.0 P2009 384
I 2009 100 (100) 120
P2006 320
Copyright ©2012 Pearson Education Chap 16-58
Index Numbers: Interpretation
DCOVA
P 288
Prices in 2000 were 90%
I 2000 2002 100 (100) 90 of base year prices
P2006 320
P 320
Prices in 2006 were 100%
I 2006 2006 100 (100) 100 of base year prices (by
P2006 320
definition, since 2006 is the
base year)
Unweighted Weighted
aggregate aggregate
price index price index
numbers numbers
(t)
i
P (t)
i = item
I
U
i1
n
100 t = time period
n = total number of items
P
i1
i
(0)
P
i1
i
(t)
= sum of the prices for the group of items at time t
n
i1
I 2009
P 2009
100
410
(100) 118.8
P 2006 345
Unweighted total expenses were 18.8%
higher in 2009 than in 2006
Copyright ©2012 Pearson Education Chap 16-62
Weighted
Aggregate Price Index Numbers
DCOVA
Laspeyres index Paasche index
n n
(t)
P i
(t)
Q (0)
i
(t)
P i
(t)
Q (t)
i
I
L
i1
n
100 I
P
i1
n
100
Pi1
i
(0)
Q (0)
i P i
(0)
Q (t)
i
i1