Forecasting: Basics Supply Chain Management Fall, 2004 Dr. Lu Note 5 1 Outline Principals of demand forecasting Time series method Isolating the trend Seasonal variation Performance evaluation A complete example Conclusion 2 Four Module in SCM Demand Forecasting – How to reduce the forecast error Managing the material flow – Manage the inventory… Coordination – To make sure the whole chain share the same objective Value of information and information technology – Value of information sharing, early marketing signal 3 Forecasting: Importance Initial step for making any decision Good forecasting can reduce the uncertainty of the demand Bad forecasting either leads to the lots of inventory or out of stock – Nike has a lot of inventory for one kind of product while out of stock for the other product The better forecast can reduce the operating cost while providing better service for the customer 4 Forecasting Forecasting – For any given information, how to reduce the uncertainty in demand Some innovation: VMI, early market signal, postpone – How to get more information so that the demand uncertainty can be reduced 5 Philosophy of Forecasting The past can tell the future in some way – The demand will not change rapidly in a short period – Read Nike’s recent story of forecasting New information is very important – When the demand changes rapidly, new information or expert opinion should be combined together with the history data to get a better forecast Trend is very important – Trend detecting techniques will be addressed Long term forecast is almost impossible – We focus on short term forecasting 6 Nike: Future Results Not Guaranteed (2003) IT'S BEEN MORE than two years since Nike Chairman Phil Knight owned up to the sneaker giant's disastrous $400 million experiment with demand forecasting software. The headlines are well known: Nike went live with its much-vaunted i2 system in June 2000, and nine months later, its executives acknowledged that they would be taking a major inventory write-off because the forecasts from the automated system had been so inaccurate. With that announcement in February 2001, Nike's stock value plummeted, along with its reputation as an innovative user of technology. 7 Nike: Future Results Not Guaranteed (2003) Relying exclusively on the automated projections, Nike ended up ordering $90 million worth of shoes, such as the Air Garnett II, that turned out to be very poor sellers. The company also came up with an $80 million to $100 million shortfall on popular models, such as the Air Force One. Nike isn't the only company with a forecasting horror story. Corporate America is littered with companies that invested heavily in demand software but have little or nothing to show for it. Goodyear, for example, implemented a demand forecasting system in mid-2000 but hasn't shown significant improvement in managing its inventory, and last year the tire company lost more money than the year before. In 2002 alone, companies spent $19 billion on demand forecasting software and other supply chain solutions, according to IDC (a sister company to CIO's publisher). 8 Past Can predict the Future? From hard experience, a growing number of CIOs now realize that computer systems alone are incapable of producing accurate forecasts. Software can't predict the future, particularly sudden, unexpected shifts in economic or market conditions. Nor can it exercise the kind of rational analysis or judgement that human beings excel at. Hence, demand forecasting technology is inherently limited, and companies such as Nike and Cisco that rely on it without an institutionalized set of human checks and balances will invariably end up in trouble 9 Past Can predict the Future? Even if a demand forecasting system had 100 percent accurate information, there is another problem: The past can't predict the future. Computer-generated forecasts use historical data to make assumptions about what will happen, but there is no way for them to anticipate major market changes. Belvedere International, which is based in Ontario, Canada, makes skin-care products. When SARS broke out in Toronto, Belvedere sold more than a year's worth of its One Step hand disinfectant in a month. No forecasting system could have predicted that. Belvedere has kept its assembly line running 16 hours a day, six days a week—modifying production of other goods in the process—just to keep pace with demand. "It's no different from forecasting the weather," says Gene Alvarez, Meta Group's vice president of technology re-search services. "Once in a while something the model couldn't figure out catches them off guard. Same thing happens with consumer taste and demand." 10 Nike In the end, the demand forecasting failure at Nike and other companies can be laid squarely on the shoulders of executives who put too much faith in technology. Court records in the lawsuits by shareholders against Nike reveal that executives for the sneaker company didn't even hold meetings to review and discuss the computerized forecasts that turned out to be so disastrously wrong. In other words, Nike management neglected to put in place a high-level process of human checks and balances for the computerized forecast. While that negligence actually enabled Nike executives to successfully argue that they were initially unaware of the flawed forecast that was generating such a huge inventory glut, it was a Pyrrhic victory. The company still lost $180 million in sneaker sales and a third of its stock market value. 11 Global Crossing Global Crossing is a major telecommunications company that provides computer networking services worldwide. It maintains a large backbone and offers transit and peering links , VPN and VoIP , mainly to large customers as it is a tier 1 carrier . It rode the wave of the 1990s to incredibly high market values, only to go bankrupt a few years later. Its stock price hit a high of US $64 per share, and would eventually plunge to below $1. Reach Global Services Ltd. (Backbone owned by Telstra and PCCW ) In January 2002, the company declared chapter 11 bankruptcy, making it the fourth largest insolvency in United States history. By December 2003 , the company completed its restructuring and emerged from bankruptcy, after Singapore Technologies Telemedia bought a two-thirds stake in the business. The ratio of demand and supply for the whole industry is less than 2.7% 12 Characteristics of forecasts Forecasts are always wrong. Should include expected value and measure of error. Long-term forecasts are less accurate than shortterm forecasts: Forecast horizon Aggregate forecasts are more accurate than disaggregate forecasts 13 Initial Step of Forecasting The more information you have, the better forecast can be made The following factors should be known – – – – – Past demand Market planning like promotions State of economy Planned price discounts Actions from your competitors and more… Example – Cisco: duplicate orders 14 CISCO SYSTEMS, INC CISCO is the worldwide leader in networking for the Internet. Cisco Internet Protocol (IP)-based networking solutions are the foundation of the Internet and most corporate, education, and government networks around the world. Cisco provides the broadest line of solutions for transporting data, voice, and video within buildings, across campuses, or around the world. Cisco was founded in 1984 by a group of computer scientists from Stanford University 15 Cisco CONSOLIDATED STATEMENTS OF OPERATIONS DATA (In millions, except per-share amounts) Years Ended July 28, 2001 July 29, 2000 July 31, 1999 Net sales $22,293 $18,928 $12,173 Income (loss) before provision for taxes $ (874) $ 4,343 $ 3,203 Net income (loss) $ (1,014) $ 2,668 $ 2,023 Net income (loss) per share—diluted $ (0.14) $ 0.36 $ 0.26 16 Forecasting Methods Subjective Forecasting Methods – subjective, human judgment – Sales force composites, customer survey, jury of executive opinion, delphi method Objective Methods: Statistics method – Causal models: assume demand forecast is highly correlated with certain factors – Time series and more – Bayisan update model and others … Objective Methods: Models from economy method – Discrete choice model (will not be discussed in this class) 17 Phases of Supply Chain Decisions Regression: Casual Method Strategy (Design) Planning Operation Forecast Time Series Method Forecast Actual Demand 18 Time Series Forecasting Historical Data Di i=1,2,…,t Forecast Time Series Model Ft+u u=1,2,… 19 Components of an observation Observed demand (O) = Systematic component + Random component (R) Trend (growth or decline in demand) Seasonality (predictable seasonal fluctuation) Filter out the random component (noise) and estimate the systematic component ! 20 Trend and Seasonality Trend(1) demand demand stationary series time time demand demand seasonality + trend time Trend(2) time 21 Elements of a Time Series Additive model: Observed demand=Trend + Seasonal +Random Multiplicative model: Observed demand=Trend * Seasonal +Random Forecasting is to identify the system term – Which are trend and seasonal terms – The observed demand minus system term should be pure random (with mean zero symmetry) 22 Steps in Forecasting Preliminary handling – Filtering, moving average Identifying the trend term – Regression – Curve fitting De-seasonalized the demand data if exist Evaluate the forecast 23 Warm-up: Parameter Estimation Suppose demand i.i.d. random variable with Normal distribution, how to do forecast? Forecast becomes estimation, how to estimate the parameters 1 t Lt = Model ∑ Di Ft +τ N i = t − N +1 = Lt , τ = 1,2,... All the data will be used to estimate the demand How to estimate the standard deviation? 24 Parameter Estimation Assumptions - No trend Equal weight to all the N observations Model 1 t Lt = Di ∑ N i = t − N +1 Ft +τ = L t , τ = 1,2,... 25 Moving Average Assumptions - No trend Equal weight to all the N observations Model Decision 1 t Lt = Di ∑ N i = t − N +1 Ft +τ = L t , τ = 1,2,... :N 26 Isolating the Trend: Moving Average Example – Quarterly data for the demand of certain product is as following: 200, 250, 175, 186, 225, 285, 305 and 190. Determine the one-period ahead forecast for the next quarter F4, F5,…, F8 by using three-period moving and 6-period moving? 27 Moving Average Multiple period ahead: Ft,t+i=Ft+1 – The reason is, we assume the demand is stationary Example – Quarterly data for the demand of certain product is as following: 200, 250, 175, 186, 225, 285, 305 and 190. Determine the forecast for the next quarter F4, F5,…, F8 by using three-period moving and 6-period moving? 28 Formula for Moving Average Ft 1 Ft 1 N Dt Dt N Show me 29 Moving average lags behind the trend Example – Suppose the demand has a linear increasing trend: 2,4,6,8,…, 24, consider the one-step ahead MA(3) and MA(6) for this series MA(3) MA(6) 30 Isolating the Trend: Moving Average When N is 2k+1, k=0,1,2,… – The moving average is written in the center of the values averaged Example – 170, 120, 105, 156, 189, 107, 167, 205 – 3-point moving average? – 5-point moving average? 31 Demand Moving Average 250 200 150 100 50 0 Series1 Series2 Series3 1 2 3 4 5 6 7 8 Time 32 Isolating the Trend: Centred Moving Average When N is 2k, the moving average will not correspondence to a point, we can use centered moving average – Do moving average first – Do average of every pair of moving average Example – 170, 120, 105, 156, 189, 107, 167, 205 – 4-point moving average? 33 Decisions About N Bigger N leads to smoother data, however decreases the number of values obtained When there is obvious seasonality, N is the length of the seasons Summary for moving average – Can be used to forecast the demand with no trend – Can be used to identify the trend by providing more smoothed data 34 Forecasting: Exponential Smoothing New Forecast= α(current observation of the demand)+ (1- α)(Last forecast) Ft 1 Dt 1 Ft , 0 1 Ft , t i Ft 1 , i 1, 2, . . . Example – Quarterly data for the demand of certain product is as following: 200, 250, 175, 186, 225, 285, 305 and 190. Determine the forecast for the next quarter F4, F5,…, F8 by using exponential smoothing for α =0.1, 0.3 ? F1 200 35 Exponential Smoothing Demnad 400 300 Series1 200 Series2 100 Series3 0 1 2 3 4 5 6 7 8 Time 36 200 200 200 250 200 200 175 205 215 186 202 203 225 200.4 197.9 285 202.86 206.03 305 211.074 229.721 190 220.4666 252.3047 37 Exponential Smoothing New Forecast= α(current observation of the demand)+ (1-\ α) (Last forecast) Ft Ft1 Ft1 D t1 – Some kind of feedback: if the previous forecast is greater than the demand, then reduce the forecast, otherwise, increase forecast – F_t=F_{t-1}- α e_{t-1}. Ft i0 1 i Dt i1 38 Comparision of Moving average and Exponential Smoothing Similarities – Both methods are more appropriate for the stationary demand – Both dependents on one parameter – Both methods will lag behind a trend if one exists Difference – The exponential smoothing is a weighted average of all the past data while the moving average is a weighted average of last N period demand 39 Isolating the Trend: Exponential Smoothing value = α(current observation of the demand)+ (1- α)(Smoothed data in the last period) St=αDt + (1-α) St-1 Example Smoothed – Quarterly data for the demand of certain product is as following: 200, 250, 175, 186, 225, 285, 305 and 190. Determine the smoothed demand by using exponential smoothing for α =0.1, 0.3 ? 40 Isolating the Trend: Exponential Smoothing St=αDt + (1-α) St-1 A low α produces a more smoothing set of trend elements and a high α is more sensitive to the changes in the trend. – Compromise is needed and usually α should be around 0.1 to 0.3. 41 350 300 250 Series1 200 Series2 150 Series3 100 50 0 1 2 3 4 5 6 7 8 42 200 200 200 250 205 215 175 202 203 186 200.4 197.9 225 202.86 206.03 285 211.074 229.721 305 220.4666 252.3047 190 217.4199 233.6133 43 Summary We present the basic ideas about demand forecasting Two methods are presented for demand forecasting – Moving average and exponential smoothing – Both the methods are lag behind the trend and so they are proper for the stationary demand Those two methods can be used to detect the trend 44 Outline Identifying the trend: Regression Holt’s method Identify the seasonal factor Winter’s method 45 Isolating the Trend Regression method n Sxy n iDi i1 Sxx b a nn 1 2 n 2 n 1 2n 1 Sxy Sxx ni1 Di n 6 demand – Linear regression n Di i1 n 2 n 1 2 4 time n 1b 2 y t a bt 46 Formula for Linear Regerssion n Sxy n iDi i1 Sxx b a nn 1 2 n 2 n 12n 1 Sxy Sxx ni1 Di n 6 n Di i1 n 2 n 1 2 4 n 1 b 2 47 Isolating Trend: Regression Example: Using the first five observation to estimate the demand in period 6, 7 and 8 – – – – – 200, 250, 175, 186, 225, 285, 305, 190 Sxy Sxx a and b Dt=? 48 The case of observation is 5 Sxy 5200 250 2 175 3 186 4 225 5 5 6 2200 250 175 186 225 70 Sxx 25 6 11 25 36 50 6 4 b Sxy / Sxx 70 1. 4 50 200 250 175 186 225 a 1. 4 5 1 211. 4 5 2 Dt 211. 4 1. 4t 49 The case of observation is 6 Sxy 6200 250 2 175 3 186 4 225 5 285 6 7 6 2200 250 175 186 225 285 Sxx 36 7 13 36 49 6 4 b Sxy / Sxx a 200 250 175 186 225 285 b61 6 2 Dt a bt ? 50 Isolating Trend: Holt’s Method St Dt 1 St 1 Gt 1 Gt St St 1 1 Gt 1 Ft , t i St iGt Example – 200, 250, 175, 186, 225, 285, 305, 190 51 Solution S0 200, G0 10, 0. 1, 0. 1 S1 D1 1 S0 G0 0. 1 200 0. 9 200 10 209 G1 S1 S0 1 G0 0. 1 209 200 0. 9 10 9. 9 S2 D2 1 S1 G1 0. 1 250 0. 9 209 9. 9 222 G2 S2 S1 1 G1 0. 1 222 209 0. 9 9. 9 10. 2 S3 D3 1 S2 G2 0. 1 175 0. 9 222 10. 2 226. 5 G3 S3 S2 1 G2 0. 1 226. 5 222 0. 9 10. 2 9. 6 F3,4 S3 1 G3 226. 5 9. 6 236. 1 F3,5 S3 2 G3 226. 5 2 9. 6 245. 7 52 Seasonal Variation: Additive Model Dt=Tt+Ct +Rt – Dt is actual demand in period t , while Tt and Ct are trend and seasonal variation in period t , Rt is the random term. Ct=Dt-Tt Group the into different group according to seasonality Computing the seasonal factor for each season by averaging the season factors The forecast = Trend +Season Examples – 35, 15, 42, 36, 19, 44, 22, 47, 45, 26, 52 – 120, 132, 106, 98, 88, 94, 119, 125, 99, 98,86, 90, 110, 119, 102, 89, 79,88,107, 114, 92, 88, 75, 80 53 35 15 30.66667 -15.6667 42 31 11 36 32.33333 3.666667 19 33 -14 44 34.66667 9.333333 41 35.66667 5.333333 22 36.66667 -14.6667 47 38 9 45 39.33333 5.666667 26 41 -15 52 S1= -14.83 S2= 9.777778 S3= 4.888889 54 60 50 40 30 20 10 0 -10 1 2 3 4 5 6 7 8 9 10 11 12 -20 55 Forecast for the next three periods T 13 43, T 14 44, T 15 45 F13 T 13 S13 T 13 S1 43 4. 89 47. 89 F14 T 14 S14 T 13 S2 44 14. 83 29. 17 F15 T 15 S15 T 15 S3 45 9. 78 54. 78 56 150 100 Series1 50 Series2 Series3 0 1 4 7 10 13 16 19 22 -50 57 Forecast for the Next 6 Periods T 25 90. 6, T 26 89. 8, T 27 89. 1 T 28 88. 3, T 29 87. 5, T 30 86. 8 C1 12. 45, C2 20. 42, C3 0. 5 C4 6. 97, C5 16. 78, C6 9. 56 F25 T 25 C25 T 25 C1 90. 6 12. 45 103 F26 T 26 C26 T 26 C2 110 F27 T 27 C27 T 27 C3 88. 6 F28 T 28 C28 T 28 C4 81. 33 F29 T 29 C29 T 29 C5 70. 72 F30 T 30 C30 T 30 C6 77. 24 58 Seasonal Variation: Multiplicative Model Dt=Tt*Ct +Rt – Dt is actual demand in period t , while Tt and Ct are trend and seasonal variation in period t Ct=Dt/Tt Group the into different group according to seasonality Computing the seasonal factor for each season by averaging the season factors The forecast = Trend *Season Example – 120, 100, 121, 138, 120, 142, 160, 138, 163, 184, 162, 182, 208, 175, 206 59 250 200 150 100 50 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 60 1.2 1 0.8 0.6 0.4 0.2 0 1 2 3 4 5 6 7 8 9 10 11 12 13 61 120 100 113.6667 0.879765 121 119.6667 1.011142 138 126.3333 1.092348 120 133.3333 0.9 142 140.6667 1.009479 160 146.6667 1.090909 138 153.6667 0.898048 163 161.6667 1.008247 184 169.6667 1.084479 162 176 0.920455 182 184 0.98913 208 188.3333 1.104425 175 196.3333 0.891341 206 0.897922 c2 1.0045 c3 1.09304 c1 62 Forecast for Next 3 Periods T 16 203, T 17 210, T 18 217 C1 1. 09, C2 0. 898, C3 1. 005 F16 T 16 C16 T 16 C1 203 1. 09 221 F17 T 17 C17 T 17 C2 210 0. 898 189 F18 T 18 C18 T 18 C3 217 1. 005 218 63 Winter’s Seasonal Variation Dt=(L+Gt)ct+et – – – – L is the base signal or intercept at time zero; G is the slope of trend et is error term that cannot be forecasted The length of the season is N and summation of ci =N St=αDt/ct-N+(1- α)(St-1 +Gt-1) Gt=β(St -St-1 )+ (1- β) Gt-1 ct= γ Dt/St+(1- γ)ct-N Ft,t+i=(St+ i* Gt )ct+i-N 64 Winter’s Seasonal Variation: Example 10, 20, 26, 17, 12, 23, 30, 22 35 30 25 20 Series1 15 10 5 0 1 2 3 4 5 6 7 8 65 Initial Data and Initial Forecast C5 0. 59, C6 1. 11, C7 1. 38, C8 0. 92 G8 0. 875, S8 23. 06 F8,9 S8 G9 C94 S8 G8 C5 23. 06 0. 875 0. 59 14. 12 F8,10 S8 2 G8 C6 27. 54 F8,11 S8 3 G8 C7 35. 44 F8,12 S8 4 G8 C8 24. 38 66 Updating the Parameter and Forecast C5 0. 59, C6 1. 11, C7 1. 38, C8 0. 92 G8 0. 875, S8 23. 06 0. 2, 0. 1, 0. 1 D9 16 S9 D9 / c5 1 S8 G8 24. 57, G9 S9 S8 1 G8 0. 9385, C9 D9 / S9 1 C5 0. 5961 F9,10 S9 G9 C6 28. 3144 F9,11 S9 2G9 C7 36. 4969 67 Updating and Forecast C5 0. 59, C6 1. 11, C7 1. 38, C8 0. 92 G8 0. 875, S8 23. 06 0. 2, 0. 1, 0. 1 D9 16, S9 24. 57, G9 0. 9385, C9 0. 5961 D10 33, S10 26. 35, G10 1. 0227, C10 1. 124 D11 34, S11 26. 83, G11 0. 9678, C11 1. 369 D12 26, S12 27. 89, G12 0. 977, C12 0. 9212 68 Finding Initial Data Moving Average to get trend Finding the ratio of the observed demand to the data obtained after moving average to find the seasonal factor Regression over the data to get trend Regression over the trend data (obtained after the smoothing) to get the trend 69 Finding Initial Data n Sxy n x i y i i1 n Sxx n x 2i i1 b a Sxy Sxx ni1 y i n y t a bt b n n xi yi i1 i1 i 2 n xi i1 in1 x i n 70 n 4, 3, 18. 5 , 4, 19. 125 , 5, 20, 6, 21. 125 c1 0. 60255, c2 1. 09339, c3 1. 41139, c4 0. 89267, n Sxy n x i yi i1 n n xi yi i1 i1 4 3 18. 5 4 19. 125 5 20 6 21. 125 3 4 5 6 18. 5 19. 125 20 21. 125 4 358. 75 18 78. 75 17. 5 n Sxx n x 2i i1 n 2 xi i1 4 86 324 20 Sxy 0. 875 Sxx ni1 yi in1 x i a b 78. 75 0. 875 4. 5 15. 75 n n 4 b y t a bt 15. 75 0. 875t 71 Finding Initial Parameter: Updating C3 0. 59, C2 1. 11, C1 1. 38, C0 0. 92 G8 0. 875, S8 15. 75 0. 2, 0. 1, 0. 1 D1 10 S9 D1 / c3 1 S0 G0 ? G1 S1 S0 1 G0 ?, C1 D1 / S1 1 C3 ? 72 Random Term If the residue of the forecast error is pure random, then we are done; otherwise, we have to use other method to process the residue terms. – One of such example will be given later as ARMA model especially AR(1) model – Remember, always that the residue term should be examined 73 Forecast Performance Evaluation et=Ft-Dt MAD=(1/n)*(|e1|+|e2|+…+|en|) MSE=(1/n)*(e12+e22+…+en2) or MSE=(1/(n-1))*(e12+e22+…+en2) 74 Summary Isolating – – – – trend Moving average and central moving average Simple exponential smoothing Regression Holt’s model (with trend) Seasonal variation Winter’s model (with trend and seasonality) 75