Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Forecasting
Chapter Outline
5.1 Introduction
5.2 Types of Forecasts
5.3 Scatter Diagrams and Time Series
5.4 Measures of Forecast Accuracy
5.5 Time-Series Forecasting Models
5.6 Monitoring and Controlling Forecasts
5.7 Using the Computer to Forecast
Introduction
“The forecast”
Step 8 Implement
Step 7 Make the forecast
Step 6 Validate the model
Step 5 Gather the data
Step 4 Select the forecasting model
Step 3 Determine the time horizon
Step 2 Select the items to be forecasted
Step 1 Determine purpose of forecast
Introduction
These steps are a systematic way of initiating,
designing, and implementing a forecasting
system
When used regularly over time, data is
collected routinely and calculations performed
automatically
There is seldom one superior forecasting
system
Different organizations may use different
techniques
Whatever tool works best for a firm is the one
they should use
Forecasting Models
Forecasting
Techniques
Figure 5.1
Consumer
Decomposition
Market Survey
Time-Series Models
Table 5.1
Scatter Diagrams
450
400
350
Annual Sales
300
250
Televisions
200
150
100
50
0
0 2 4 6 8 10 12
Time (Years)
Evaluating Forecasts
Forecasts
Demands
MAD
forecast error
n
Measures of Forecast Accuracy
Using a naïve forecasting model: Ft = At-1
Table 5.2
Measures of Forecast Accuracy
Using a naïve forecasting model
MAD
YEAR
SALES
ACTUAL
forecast error
OF CD
PLAYERS
160 ABSOLUTE VALUE OF
SALES 17.8 (ACTUAL – FORECAST)
FORECAST ERRORS (DEVIATION),
1 n
110 —9 —
2 100 110 |100 – 110| = 10
3 120 100 |120 – 110| = 20
4 140 120 |140 – 120| = 20
5 170 140 |170 – 140| = 30
6 150 170 |150 – 170| = 20
7 160 150 |160 – 150| = 10
8 190 160 |190 – 160| = 30
9 200 190 |200 – 190| = 10
10 190 200 |190 – 200| = 10
11 — 190 —
Sum of |errors| = 160
MAD = 160/9 = 17.8
Table 5.2
Measures of Forecast Accuracy
There are other popular measures of forecast accuracy
The mean squared error
MSE
( error) 2
n
The mean absolute percent error
error
actual
MAPE 100%
n
And bias is the average error
bias
error
n
Time-Series Forecasting Models
Trend
Component
Seasonal Peaks
Actual
Demand
Line
Average Demand
over 4 Years
| | | |
Year Year Year Year
1 2 3 4
Time
Figure 5.3
Decomposition of a Time-Series
Yt Yt 1 ... Yt n1
Ft 1
n
where
Ft 1 = forecast for time period t + 1
Yt = actual value in time period t
n = number of periods to average
Wallace Garden Supply’s Three-
Month Moving Average
MONTH ACTUAL SHED SALES THREE-MONTH MOVING AVERAGE
January 10
Forecasted
February 12
values
March 13
April 16 (10 + 12 + 13)/3 = 11.67
May 19 (12 + 13 + 16)/3 = 13.67
June 23 (13 + 16 + 19)/3 = 16.00
July 26 (16 + 19 + 23)/3 = 19.33
August 30 (19 + 23 + 26)/3 = 22.67
September 28 (23 + 26 + 30)/3 = 26.33
October 18 (26 + 30 + 28)/3 = 28.00
November 16 (30 + 28 + 18)/3 = 25.33
December 14 (28 + 18 + 16)/3 = 20.67
January — (18 + 16 + 14)/3 = 16.00
Table 5.3
Weighted Moving Averages
Weighted moving averages use weights to put
more emphasis on recent periods
Often used when a trend or other pattern is
emerging
Ft 1
( Weight in period i )( Actual value in period)
( Weights)
Mathematically
w1Yt w2Yt 1 ... wnYt n1
Ft 1
w1 w2 ... wn
where
wi = weight for the ith observation
Wallace Garden Supply Example
Program 5.1A
Wallace Garden Supply Example
Program 5.1B
Exponential Smoothing
Exponential smoothing is easy to use and
requires little record keeping of data
It is a type of moving average
Ft 1 Ft (Yt Ft )
where
Ft+1 = new forecast (for time period t + 1)
Ft = pervious forecast (for time period t)
= smoothing constant (0 ≤ ≤ 1)
Yt = pervious period’s actual demand
Table 5.5
Selecting the Best Value of
ACTUAL ABSOLUTE ABSOLUTE
TONNAGE FORECAST DEVIATIONS FORECAST DEVIATIONS
QUARTER UNLOADED WITH = 0.10 FOR = 0.10 WITH = 0.50 FOR = 0.50
1 180 175 5….. 175 5….
2 168 175.5 7.5.. 177.5 9.5..
3 159 174.75 15.75 172.75 13.75
4 175 173.18 1.82 165.88 9.12
5 190 173.36 16.64 170.44 19.56
6 205 175.02 29.98 180.22 24.78
7 180 178.02 1.98 192.61 12.61
8 182 178.22 3.78 186.30 4.3..
Sum of absolute deviations 82.45 98.63
Σ|deviations|
MAD = = 10.31 MAD = 12.33
n
Table 5.6
Best choice
Port of Baltimore Example
Program 5.2A
Port of Baltimore Example
Program 5.2B
Exponential Smoothing with Trend
Adjustment
Forecast including trend (FITt+1) = new forecast (Ft+1) + trend correction (Tt+1)
FITt 1 Ft 1 Tt 1
Ft 1 Ft Yt Ft
Tt is computed by
Tt 1 (1 )Tt ( Ft 1 Ft )
where
Tt+1 = smoothed trend for period t + 1
Tt = smoothed trend for preceding period
= trend smooth constant that we select
Ft+1 = simple exponential smoothed forecast for period t + 1
Ft = forecast for pervious period
Selecting a Smoothing Constant
As with exponential smoothing, a high value of
makes the forecast more responsive to changes in
trend
A low value of gives less weight to the recent trend
and tends to smooth out the trend
Values are generally selected using a trial-and-error
approach based on the value of the MAD for different
values of
Simple exponential smoothing is often referred to as
first-order smoothing
Trend-adjusted smoothing is called second-order,
double smoothing, or Holt’s method
Exponential Smoothing With Trend Adjustment -Example
An electronics company is selling portable CD players and estimated the demand for the first period and
forecasted the next three periods' adjusted demand using the Adjusted Exponential Smoothing model.
The first periods demand is 50 players and 54 players was used to start the forecast. α= 0.2 and β = 0.7
Unadjusted Adjusted
Period Demand Forecast Ft Trend Tt Forecast FITt
1 54 50 0 -
2 57 50.8 0.56 51.36
3 44 - - -
Yˆ b0 b1 X
where
Ŷ = predicted value
b0 = intercept
b1 = slope of the line
X = time period (i.e., X = 1, 2, 3, …, n)
Trend Projection
Yˆ b0 b1 X *
Dist7
b1
( X X )(Y Y )
(X X )
Value of Dependent Variable
Dist5 * Dist6
* Dist3 * b0 Y b1 X
Dist4
X average (mean) of X values
Dist1 * Dist2
* X
n
* Y
Y average (mean) of Y values
n
Time
Midwestern Manufacturing
Company Example
Midwestern Manufacturing Company has
experienced the following demand for it’s electrical
generators over the period of 2001 – 2007
Table 5.7
Midwestern Manufacturing
Company Example
Notice code
instead of
actual years
Program 5.3A
Midwestern Manufacturing
Company Example
Program 5.3B
Midwestern Manufacturing
Company Example
160 –
150 –
140 –
Trend Line
130 –
Generator Demand
Yˆ 56.71 10.54 X
120 –
110 –
100 –
90 –
80 –
70 – Actual Demand Line
60 –
50 –
| | | | | | | | |
Program 5.4A
Midwestern Manufacturing
Company Example
Program 5.4B
Seasonal Variations
A seasonal index indicates how a
particular season compares with an
average season
When no trend is present, the seasonal
index can be found by dividing the
average value for a particular season by
the average of all the data
Eichler Supplies:
Seasonal Index Example
AVERAGE AVERAGE AVERAGE
SALES DEMAND
TWO- YEAR MONTHLY SEASONAL
MONTH YEAR 1 YEAR 2 DEMAND DEMAND INDEX
January 80 100 90 94 0.957
February 85 75 80 94 0.851
March 80 90 85 94 0.904
April 110 90 100 94 1.064
May 115 131 123 94 1.309
June 120 110 115 94 1.223
July 100 110 105 94 1.117
August 110 90 100 94 1.064
September 85 95 90 94 0.957
October 75 85 80 94 0.851
November 85 75 80 94 0.851
December 80 80 80 94 0.851
Total average demand = 1,128
1,128 Average two-year demand
Average monthly demand = = 94 Seasonal index =
12 months Average monthly demand
Table 5.8
Seasonal Variations
We then use the seasonal indices to adjust future forecast. For example,
suppose we expected the third year’s annual demand for answering machines
to be 1,200 units (one year)
1,200 1,200
Jan. 0.957 96 July 1.117 112
12 12
1,200 1,200
Feb. 0.851 85 Aug. 1.064 106
12 12
1,200 1,200
Mar. 0.904 90 Sept. 0.957 96
12 12
1,200 1,200
Apr. 1.064 106 Oct. 0.851 85
12 12
1,200 1,200
May 1.309 131 Nov. 0.851 85
12 12
1,200 1,200
June 1.223 122 Dec. 0.851 85
12 12
Seasonal Variations with Trend
When both trend and seasonal components are present,
the forecasting task is more complex
Seasonal indices should be computed using a centered
moving average (CMA) approach
There are four steps in computing seasonal indices
Table 5.9
Seasonal
Definite trend pattern
Turner Industries Example
To calculate the CMA for quarter 3 of year 1 we compare the
actual sales with an average quarter centered on that time
period
There are two seasonal Index for quarter 1 = I1 = (0.851 + 0.848)/2 = 0.85
ratios for each quarter so Index for quarter 2 = I2 = (0.965 + 0.960)/2 = 0.96
these are averaged to get Index for quarter 3 = I3 = (1.136 + 1.127)/2 = 1.13
the seasonal index
Index for quarter 4 = I4 = (1.051 + 1.063)/2 = 1.06
Turner Industries Example
Scatter plot of Turner Industries data and CMAs
200 – CMA
150 –
Sales
100 –
50 –
Original Sales Figures
0– | | | | | | | | | | | |
1 2 3 4 5 6 7 8 9 10 11 12
Time Period
Figure 5.6
The Decomposition Method of
Forecasting
Decomposition is the process of isolating linear
trend and seasonal factors to develop more
accurate forecasts
There are five steps to decomposition
1. Compute seasonal indices using CMAs
2. Deseasonalize the data by dividing each number by
its seasonal index
3. Find the equation of a trend line using the
deseasonalized data
4. Forecast for future periods using the trend line
5. Multiply the trend line forecast by the appropriate
seasonal index
Turner Industries –
Decomposition Method
SALES SEASONAL DESEASONALIZED
($1,000,000s) INDEX SALES ($1,000,000s)
108 0.85 127.059
125 0.96 130.208
150 1.13 132.743
141 1.06 133.019
116 0.85 136.471
134 0.96 139.583
159 1.13 140.708
152 1.06 143.396
123 0.85 144.706
142 0.96 147.917
168 1.13 148.673
165 1.06 155.660
Table 5.11
Turner Industries –
Decomposition Method
Find a trend line using the deseasonalized data
b1 = 2.34 b0 = 124.78
Yˆ a b1 X 1 b2 X 2 b3 X 3 b4 X 4
where
X1 = time period
X2 = 1 if quarter 2, 0 otherwise
X3 = 1 if quarter 3, 0 otherwise
X4 = 1 if quarter 4, 0 otherwise
Regression with Trend and
Seasonal Components
Program 5.6A
Regression with Trend and
Seasonal Components
where MAD
forecast error
n
Monitoring and Controlling Forecasts
Signal Tripped
Upper Control Limit Tracking Signal
+
Acceptable
0 MADs Range
–
Lower Control Limit
Time
Figure 5.7
Monitoring and Controlling Forecasts
MAD
forecast error 85
14.2
n 6
RSFE 35
Tracking signal 2.5MADs
MAD 14.2
Adaptive Smoothing
Trend Projection:
Yˆ b0 b1 X where
Ŷ = predicted value
X = time period (i.e., X = 1, 2, 3, …, n)
b1
( X X )(Y Y )
X average (mean) of X values
(X X ) 2
X
n
b0 Y b1 X Y
Y average (mean) of Y values
n
Summary
four steps in computing seasonal indices
1. Compute the CMA for each observation (where possible)
2. Compute the seasonal ratio = Observation/CMA for that observation
3. Average seasonal ratios to get seasonal indices
4. If seasonal indices do not add to the number of seasons, multiply each
index by (Number of seasons)/(Sum of indices)
five steps to decomposition
1. Compute seasonal indices using CMAs
2. Deseasonalize the data by dividing each number by its seasonal index
3. Find the equation of a trend line using the deseasonalized data
4. Forecast for future periods using the trend line
5. Multiply the trend line forecast by the appropriate seasonal index
Q1/2008 236
Q2/2008 189
220.6=0.5*236+189+245
Q3/2008 245 1.111= 245/220.6 1.105=(1.111+1.099)/2
+208+0.5*245
Q4/2008 208 223 0.933 0.921
Q1/2009 245 225.3 1.087 1.1035
Q2/2009 199 226.9 0.877 0.87
Q3/2009 253 230.3 1.099 1.105
Q4/2009 213 234.4 0.909 0.921
Q1/2010 267 238.3 1.12 1.1035
Q2/2010 210 243.4 0.863 0.87
Q3/2010 273 1.105
Q4/2010 234 0.921
Q1/2011 1.1035
Example
Additive
Seaso
Forecasted Decom.Model
Sale nal Deseasonalize Forecasted
Periods Base Values (Y=232.8+3.313X1-
s Indice d Sales Sales
(Y=3.351X+209) 53.313X2+1.042X3-
s
40.938X4)
1.Q1/2008 236 1.1035 213.9=236/1.1035 212.4=3.351*1+209 234.4=212.4*1.1035 236.1
2.Q2/2008 189 0.87 217.2 215.7=3.351*2+209 187.7 186.1
3.Q3/2008 245 1.105 221.7 219.1 242.1 243.8
4.Q4/2008 208 0.921 225.8 222.4 204.8 205.1
5.Q1/2009 245 1.1035 222 225.8 249.2 249.4
6.Q2/2009 199 0.87 228.7 229.1 199.3 199.4
7.Q3/2009 253 1.105 229 232.5 256.9 257
8.Q4/2009 213 0.921 231.3 235.8 217.2 218.4
9.Q1/2010 267 1.1035 242 239.2 264 262.6
10.Q2/2010 210 0.87 241.4 242.5 211 212.6
11.Q3/2010 273 1.105 247.1 245.9 271.7 270.3
12.Q4/2010 234 0.921 254.1 249.2 229.5 231.6
13.Q1/2011 1.1035 252.6 278.7 275.9