Example: tourism industry

Time Series and Forecasting - Saed Sayad

1 time Series and ForecastingTime Series A time Series is a sequence of measurements over time , usually obtained at equally spaced intervals Daily Monthly Quarterly Yearly2 Dow Jones Industrial Average7000800090001000011000120001/3/00 5/3/009/3/001/3/015/3/019/3/011/3/025/3/ 029/3/021/3/035/3/039/3/03 Dat eClosing ValueTime Series ExampleComponents of a time Series Secular Trend Linear Nonlinear Cyclical Variation Rises and Falls over periods longer than one year Seasonal Variation Patterns of change within a year, typically repeating themselves Residual Variation3 Components of a time Seriestt t t tY=T+C+S+RTime Series with Linear TrendYt= a + b t + et4 time Series with Linear TrendAOL Subscribers05101520253023 412 3412 3412 341 2341 23 QuarterNumber of Subscribers (millions)199519961997199819992000 time Series with Linear TrendAverage Daily Visits in August to Emergency Room at Richmond Memorial Hospital02040608010012014012345678910 YearAverage Daily Visits5 time Series with Nonlinear TrendImports0204060801001201401601801986 198819901992199419961998 YearImports (MM)

Time Series and Forecasting Time Series • A time series is a sequence of measurements over time, usually obtained at equally spaced intervals – Daily – Monthly – Quarterly – Yearly. 2 Dow Jones Industrial Average 7000 8000 9000 10000 11000 12000

Tags:

  Series, Time, Time series, Forecasting, Time series and forecasting, Time series and forecasting time series

Information

Domain:

Source:

Link to this page:

Please notify us if you found a problem with this document:

Other abuse

Transcription of Time Series and Forecasting - Saed Sayad

1 1 time Series and ForecastingTime Series A time Series is a sequence of measurements over time , usually obtained at equally spaced intervals Daily Monthly Quarterly Yearly2 Dow Jones Industrial Average7000800090001000011000120001/3/00 5/3/009/3/001/3/015/3/019/3/011/3/025/3/ 029/3/021/3/035/3/039/3/03 Dat eClosing ValueTime Series ExampleComponents of a time Series Secular Trend Linear Nonlinear Cyclical Variation Rises and Falls over periods longer than one year Seasonal Variation Patterns of change within a year, typically repeating themselves Residual Variation3 Components of a time Seriestt t t tY=T+C+S+RTime Series with Linear TrendYt= a + b t + et4 time Series with Linear TrendAOL Subscribers05101520253023 412 3412 3412 341 2341 23 QuarterNumber of Subscribers (millions)199519961997199819992000 time Series with Linear TrendAverage Daily Visits in August to Emergency Room at Richmond Memorial Hospital02040608010012014012345678910 YearAverage Daily Visits5 time Series with Nonlinear TrendImports0204060801001201401601801986 198819901992199419961998 YearImports (MM) time Series with Nonlinear Trend Data that increase by a constant amount at each successive time period show a linear trend.

2 Data that increase by increasing amounts at each successive time period show a curvilinear trend. Data that increase by an equal percentage at each successive time period can be made linear by applying a logarithmic time Series transformed to a Linear time Series with a Logarithmic Transformationlog(Yt) = a + b t + etTransformed time SeriesLog (Imports)7 time Series with both Trend and Seasonal PatternQuarterly Power Loads50751001251501752001234123412341234 12341234123412341234123412341234 Year and QuarterPower Load198819901992199419961998198919911993 199519971999 Model Building For the Power Load data What kind of trend are we seeing? Linear Logarithmic Polynomial How can we smooth the data? How do we model the distinct seasonal pattern?

3 8 Power Load Data with Linear TrendQuarterly Power Loadsy = + = and QuarterPower Load198819901992199419961998198919911993 199519971999 Linear Trend LineModeling a Nonlinear Trend If the time Series appears to be changing at an increasing rate over time , a logarithmic model in Y may work:ln(Yt) = a + b t + etorYt= exp{a + b t + et } In Excel, this is called an exponential model9 Modeling a Nonlinear Trend If the time Series appears to be changing at a decreasing rate over time , a logarithmic model in t may work:Yt= a + b ln(t) + et In Excel, this is called a logarithmic modelPower Load Data with Exponential TrendQuarterly Power Loadsy = = and QuarterPower Load198819901992199419961998198919911993 199519971999Ln(y) = + = (in y) Trend Line10 Power Load Data with Logarithmic TrendQuarterly Power Loadsy = (t) + = and QuarterPower Load198819901992199419961998198919911993 199519971999 Logarithmic (in t) Trend LineModeling a Nonlinear Trend General curvilinear trends can often be model with a polynomial.

4 Linear (first order)Yt= a + b t + et Quadratic (second order)Yt= a + b1t + b2t2+ et Cubic (third order)Yt= a + b1t + b2t2+ b3t3+ et11 Power Load Data modeled with Second Degree Polynomial TrendQuarterly Power Loadsy = + + = and QuarterPower Load198819901992199419961998198919911993 199519971999 Second Order Polynomial Trend LineMoving Average Another way to examine trends in time Series is to compute an average of the last m consecutive observations A 4-point moving average would be:tt-1t-2t-3MA(4)(y +y +y +y )y=412 Moving Average In contrast to modeling in terms of a mathematical equation, the moving average merely smooths the fluctuations in the data. A moving average works well when the data have a fairly linear trend a definite rhythmic pattern of fluctuationsPower Load Data with 4-point Moving AverageQuarterly Power Loads50751001251501752001234123412341234 12341234123412341234123412341234 Year and QuarterPower Load198819901992199419961998198919911993 19951997199913 Power Load Data with 8-point Moving AverageQuarterly Power Loads50751001251501752001234123412341234 12341234123412341234123412341234 Year and QuarterPower Load198819901992199419961998198919911993 199519971999 Exponential Smoothing An exponential moving average is a weighted average that assigns positive weights to the current value and to past values of the time Series .

5 It gives greater weight to more recent values, and the weights decrease exponentially as the Series goes farther back in Weighted Moving Average11ttt-12tt-1 t-2S=YS = wY + (1- w)S=wY +w(1- w)Y+w(1- w)Y+"Exponentially Weighted Moving Average11221213323 2 14434 321S=YS = + (1- ) + = + (1- ) + + = + (1- ) + + + w= Weightsww*(1-w)w*(1-w)2w*(1-w)3w*(1-w) Smoothing The choice of w affects the smoothness of Et. The smaller the value of w, the smoother the plot of Et. Choosing w close to 1 yields a Series much like the original Load Data with Exponentially Weighted Moving Average (w=.34)Quarterly Power Loads50751001251501752001234123412341234 12341234123412341234123412341234 Year and QuarterPower Load198819901992199419961998198919911993 199519971999 Forecasting with Exponential Smoothing The predicted value of the next observation is the exponentially weighted average corresponding to the current observation.

6 T+1ty=S17 Assessing the Accuracy of the Forecast Accuracy is typically assessed using either the Mean Squared Error or the Mean Absolute Deviation() n2ttt=1nttt=1y-yMSE =ny-yMAD =nAssessing the Accuracy of the Forecast It is usually desirable to choose the weight w to minimize MSE or MAD. For the Power Load Data, the choice of w = .34 was based upon the minimization of Load Data with Forecast for 2000 using Exponentially Weighted Moving Average (w=.34)Quarterly Power Loads50751001251501752001234123412341234 123412341234123412341234123412341234 Year and QuarterPower Load198819901992199419961998198919911993 1995199719992000 Exponential Smoothing One Parameter (w) Forecasted Values beyond the range of the data, into the future, remain the same.

7 Two Parameter Adds a parameter (v) that accounts for trend in the ParameterExponential Smoothing()()ttt-1t-1ttt-1t-1S=wY+(1- w)S+TT=vS-S +(1-v)TThe forecasted value of y is t+1tty=S+T2 ParameterExponential Smoothing The value of Stis a weighted average of the current observation and the previous forecast value. The value of Ttis a weighted average of the change in Stand the previous estimate of the trend Load Data with Forecast for 2000 using 2 Parameter Exponential Smoothing with w=.34 and v=.08 Quarterly Power Loads50751001251501752001234123412341234 123412341234123412341234123412341234 Year and QuarterPower Load198819901992199419961998198919911993 1995199719992000 Exponential Smoothing One Parameter (w) Determines location.

8 Two Parameter Adds a parameter (v) that accounts for trend in the data. Three Parameter Adds a parameter (c) that accounts for ParameterExponential Smoothing()()ttt-1t-1t-pttt-1t-1tpt-pnYS =w +(1-w)S +TIT=vS-S +(1-v)TYI=c +(1-c)ISThe forecasted value of y is t+1ttty=S+T+I3 ParameterExponential Smoothing The value of Itrepresents a seasonal index at point p in the Load Data with Forecast for 2000 using 3 Parameter Exponential Smoothing with w=.34, v=.08, c=.15 Quarterly Power Loads50751001251501752001234123412341234 123412341234123412341234123412341234 Year and QuarterPower Load198819901992199419961998198919911993 1995199719992000 Modeling Seasonality Seasonality can also be modeled using dummy (or indicator) variables in a regression Seasonality For the Power Load data, both trend and seasonality can be modeled as follows.

9 Yt= a + b1t + b2t2+ b3Q1+ b4Q2+ b5Q3+ etwhere 1231if quarter 1Q=0if quarters 2, 3, 41if quarter 2Q=0ifquarters1,3,41if quarter 3Q=0ifquarters1,2,4 Power Load Data modeledfor both Trend and SeasonalityQuarterly Power Loads50751001251501752001234123412341234 12341234123412341234123412341234 Year and QuarterPower LoadPow er LoadPredicted198819901992199419961998198 919911993199519971999y = + + - + + = Power LoadsPredicted Quarterly Power Loads50751001251501752001234123412341234 1234123412341234 1234123412341234 Year and QuarterPower LoadPredicted198819901992199419961998198 919911993199519971999y = + + - + + =


Related search queries