introduction to forecasting (part 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · to...

35
INTRODUCTION TO FORECASTING (PART 2) AMAT 167

Upload: vankien

Post on 22-Mar-2018

218 views

Category:

Documents


4 download

TRANSCRIPT

Page 1: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

INTRODUCTION TO FORECASTING

(PART 2)AMAT 167

Page 2: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

Techniques for Trend

Page 3: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLEOFTRENDS

Inourdiscussion,wewillfocusonlineartrend…

buthereareexamplesofnon-lineartrends:

Page 4: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLEOFTRENDS

Ifyouwanttostudyothertechniquesforfindingtrends,studysignalanalysis.

Page 5: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

LINEARTRENDEQUATION

Page 6: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

LINEARTRENDEQUATION

Page 7: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

HOWTOCOMPUTEFORa ANDb FROMDATA

• Wecanusetheformulainlinearregression• MSExcelalsohasafeatureforautomaticallycomputingtheparameters• InMSExcel,youcanalsocomputeforR2.

Page 8: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

TREND-ADJUSTEDEXPONENTIALSMOOTHING(DOUBLESMOOTHING)

• Thisisusedwhendatavaryaroundanaverageorhavesteporgradualchanges.• Ifaseriesexhibitstrend,andsimplesmoothingisusedonit,theforecastswillalllagthetrend:Ifthedataareincreasing,eachforecastwillbetoolow;ifdecreasing,eachforecastwillbetoohigh.

Page 9: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

TREND-ADJUSTEDEXPONENTIALSMOOTHING(DOUBLESMOOTHING)

Thetrend-adjustedforecast(TAF)is

Estimatefortheslope

Page 10: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLE

Period Actual(At) Tt St TAFt Error1 7002 724 24 7003 720 10 724 724 -44 728 10 731.6 734 -65 740 9.28 740.96 741.6 -1.66 742 9.088 746.944 750.24 -8.247 758 8.0992 756.8192 756.032 1.9688 750 8.33536 758.95104 764.9184 -14.91849 770 6.545152 768.37184 767.2864 2.713610 775 6.870784 774.950195 774.916992 0.08300811 FUTURE 781.820979

alpha=0.4beta=0.3

Page 11: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLE

690700710720730740750760770780790

0 2 4 6 8 10 12

Actual(At) TAFt SimpleExponentialSmoothing

Page 12: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

Techniques for Seasonality

Page 13: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLEOFSEASONALITY

• weathervariations(e.g.,salesofwinterandsummersportsequipment)• vacationsorholidays(e.g.,airlinetravel,greetingcardsales,visitorsattouristandresortcenters)• daily,weekly,monthly,andotherregularlyrecurringpatternsindata(e.g.,rushhourtrafficoccurstwiceaday—incominginthemorningandoutgoinginthelateafternoon)

Page 14: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXPRESSIONOFSEASONALITY

• Iftheseriestendstovaryaroundanaveragevalue,thenseasonalityisexpressedintermsofthataverage(oramovingaverage).• Iftrendispresent,seasonalityisexpressedintermsofthetrendvalue.

Page 15: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

MODELSOFSEASONALITY

expressed as a quantity (e.g., 20 units), which is added to or subtracted from the series average

expressed as a percentage of the average (or trend) amount (e.g., 1.10), which is then used to multiply the value of a series

Page 16: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

WEWILLUSETHEMULTIPLICATIVEMODEL(COMMONLYUSED)

• Seasonalpercentagesinthemultiplicativemodelarereferredtoasseasonalrelativesorseasonalindexes.• SupposethattheseasonalrelativeforthequantityoftoyssoldinMayatastoreis1.20.Thisindicatesthattoysalesforthatmonthare20percentabovethemonthlyaverage.• Aseasonalrelativeof.90forJulyindicatesthatJulysalesare90percentofthemonthlyaverage.

Page 17: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

REMARKS

• Knowledgeoftheextentofseasonalityinatimeseriescanenableonetoremoveseasonalityfromthedata(i.e.,toseasonallyadjustdata)inordertodiscernotherpatternsorthelackofpatternsintheseries.• Seasonalrelativesareusedintwodifferentwaysinforecasting.Onewayistodeseasonalize data;theotherwayistoincorporateseasonalityinaforecast.

Page 18: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

DESEASONALIZING THEDATA

• Wewanttoremovetheseasonalcomponentfromthedatainordertogetaclearerpictureofthenonseasonal (e.g.,trend)components.• Deseasonalizing dataisaccomplishedbydividingeachdatapointbyitscorrespondingseasonalrelative(e.g.,divideNovemberdemandbytheNovemberrelative,divideDecemberdemandbytheDecemberrelative,andsoon).

Page 19: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLE

Period Quarter Sales QuarterRelative(given) DeseasonalizedSales1 1 158.4 1.2 1322 2 153 1.1 139.09090913 3 110 0.75 146.66666674 4 146.3 0.95 1545 1 192 1.2 1606 2 187 1.1 1707 3 132 0.75 1768 4 173.8 0.95 182.9473684

Page 20: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLE

0

50

100

150

200

250

0 2 4 6 8 10

Sales DeseasonalizedSales

Page 21: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

INCORPORATINGSEASONALITYINAFORECAST

Steps:1. Obtaintrendestimatesfordesiredperiodsusingatrend

equation.2. Addseasonalitytothetrendestimatesbymultiplyingthesetrend

estimatesbythecorrespondingseasonalrelative(e.g.,multiplytheNovembertrendestimatebytheNovemberseasonalrelative,multiplytheDecembertrendestimatebytheDecemberseasonalrelative,andsoon).

Page 22: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLE

y=3.3274x+141.59R²=0.08656

0

50

100

150

200

250

0 2 4 6 8 10

Sales Linear(Sales)

Note:Youcanalsousethetrendlinegeneratedbythedeseasonalizeddatawhichisy=7.3473x +124.53

R² =0.99837

Page 23: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLE

Period Quarter Sales QuarterRelative(given) SeasonalizedSales1 1 158.4 1.22 2 153 1.13 3 110 0.754 4 146.3 0.955 1 192 1.26 2 187 1.17 3 132 0.758 4 173.8 0.959 1 171.5366 1.2 205.84392

(forecastusingtrendline)

Page 24: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

COMPUTINGSEASONALRELATIVESUSINGSIMPLEAVERAGEMETHOD

• Whenthedatahaveastationarymean(i.e.,variationaroundanaverage),theSAmethodworksquitewell.• Itcanbeusedtoobtainfairlygoodvaluesofseasonalrelativesaslongasthevariations(seasonalandrandom)aroundthetrendlinearelargerelativetotheslopeoftheline.• AnotherapproachistheCenteredMovingAverage:Thisapproacheffectivelyaccountsforanytrend(linearorcurvilinear)thatmightbepresentinthedata.

Page 25: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

COMPUTINGSEASONALRELATIVESUSINGSIMPLEAVERAGEMETHOD

Page 26: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

EXAMPLE

STEP1 STEP2Season Week1 Week2 Week3 SeasonAverage SAIndexTues 67 60 64 63.66666667 0.88955422Wed 75 73 76 74.66666667 1.04324684Thurs 82 85 87 84.66666667 1.1829674Fri 98 99 96 97.66666667 1.36460413Sat 90 86 88 88 1.22954092Sun 36 40 44 40 0.55888224Mon 55 52 50 52.33333333 0.73120426

OVERALLAVERAGE= 71.57142857

Page 27: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

NOTES ABOUT ASSOCIATIVE/CASUAL FORECASTING: LINEAR REGRESSION

Page 28: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

WARNING!

Wewillnotdiscusslinearregressionanymore.However,pleasetakenoteofthefollowing(youknowtheseifyouhavetakenSTAT101,STAT166etc).Useofsimpleregressionanalysisimpliesthatcertainassumptionshavebeensatisfied,suchas• Variationsaroundthelinearerandom.Iftheyarerandom,nopatternssuchascyclesortrendsshouldbeapparentwhenthelineanddataareplotted.

• Deviationsaroundtheaveragevalue(i.e.,theline)shouldbenormallydistributed.

Moreover,oneneedsaconsiderableamountofdatatoestablishthelinearrelationship—inpractice,20ormoreobservations.

Page 29: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

Monitoring the ForecastUsing Control Chart

Page 30: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

CONTROLCHART

Page 31: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

DETECTNONRANDOMNESS,EXAMPLES:

Page 32: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

CREATINGCONTROLCHARTS

• Controlchartsarebasedontheassumptionthatwhenerrors(Actual-Forecast)arerandom,theywillbedistributedaccordingtoanormaldistributionaroundameanofzero.• Recallthatforanormaldistribution,approximately95.5percentofthevalues(errorsinthiscase)canbeexpectedtofallwithinlimitsof0±2s (i.e.,0±2standarddeviations),andapproximately99.7percentofthevaluescanbeexpectedtofallwithin±3s ofzero.

• Weapproximates, 𝑠 ≈ 𝑀𝑆𝐸�

Page 33: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

CREATINGCONTROLCHARTS

Forexample,z canbe2or3.

Page 34: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

DETECTINGBIAS

A value of zero would be ideal; limits of ±4 or ±5 are often used for a range of acceptable values of the tracking signal.

Page 35: INTRODUCTION TO FORECASTING (PART 2)jfratup.weebly.com/.../amat_167_forecasting_2.pdf · TO FORECASTING (PART 2) AMAT167. Techniques for Trend. EXAMPLE OF TRENDS ... Seasonalized

DETECTINGBIAS(ALTERNATIVE)

MAD that is updated and smoothed (SMAD) using exponential smoothing