1 / 23

Lecture: Intro to Forecasting

Lecture: Intro to Forecasting. April 2, 2014. Question. What is your primary personal computing platform? Mac Windows I have and use both a Mac and PC Other ( eg , Linux/Unix/BSD) I don’t have a personal computer. I only use the lab machines. Administrative.

lyre
Download Presentation

Lecture: Intro to Forecasting

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Lecture:Intro to Forecasting April 2, 2014

  2. Question • What is your primary personal computing platform? • Mac • Windows • I have and use both a Mac and PC • Other (eg, Linux/Unix/BSD) • I don’t have a personal computer. I only use the lab machines.

  3. Administrative • Problem set 8: posted soon, due next Wednesday • Final quiz (quiz 5): 1 week from this coming Monday (14/4) • Exam 3: 2 weeks from this coming Monday (21/4) • Final exam: 3 weeks from this coming Monday (28/4) • Yikes!

  4. Time Series • Many business related data analysis problems relate to predicting future amounts (sales, costs, prices, etc.) • The key think about time series is that there is an explicit order in the data that we can exploit: time. • We’ve already touched on time series analysis but now we’ll examine it more in depth. • The book touches on it briefly, but not enough. Two scanned readings on my website under /Readings: • Smoothing methods (today/next time) • Time Series (next time)

  5. Decomposing a Time Series Now we’ll often look and think about the “x-axis” as time: • Forecast: prediction of a future value of a time series that extrapolates from historical patterns

  6. Decomposing a Time Series • Unfortunately different people use slightly different terminology • Cyclical patterns:

  7. Decomposing a Time Series • Seasonality:

  8. Decomposing a Time Series • Components: • Trend: estimated linear pattern • Seasonal: regular “up and down” oscillations related to the calendar. Most commonly seasonal patterns that are the same or similar from year to year. • Irregular: irregular variation. Assumed to be random error.

  9. Smoothing • Smoothing: • Removing irregular and seasonal components of a time series to enhance the visibility of a trend. Can visually helpful but can also be misleading.

  10. Seasonality • Seasonally Adjusted • Removing the seasonal component of a time series • Many economic and gov’t reports are seasonally adjusted.

  11. Moving Averages • Moving Average: A (sometimes weighted) average of adjacent values of a time series • More terms that are averaged, the smoother the estimate. • Centered moving average with a span=5

  12. Moving Averages • Moving Average: A (sometimes weighted) average of adjacent values of a time series • More terms that are averaged, the smoother the estimate. • Centered moving average with a span=5 but in Finance (and much of the business world) it’s more common to only use the previous observationsto calculate the moving average: span = 5

  13. Question • Using a moving average with a span of 3, forecast the closing price of the SPY on 4-Feb-14 • 178.25 • 177.19 • 177.6 • I have no idea

  14. Example • Time series plots in StatTools • Moving average with varying span amounts

  15. Measures of Performance There are several common measures of a forecast model’s accuracy:

  16. Question • What is the MAPE of moving average forecast with a span of 5 using the New Orders dataset? • 14.5% • 9.7% • 13.6% • 12.2%

  17. Exponential Smoothing • EWMA: Exponentially Weighted Moving Averages. • The book refers to as weights: wt • I’ll refer to αt = (1 – wt) • This is how StatTools refers to them • As previously mention there are some differences in notion depending on field, etc… • It is no different – just a slight change in notation to help you with using StatTools

  18. Exponential Smoothing We’ll talk about 3 types of exponential smoothing: • Simple: appropriate for a series with no pronounced trend or seasonality • Holt’s method: appropriate for a series with a trend but no seasonality. Not in the book, but scanned reading. • Winters’ method: for a series with seasonality (and possible trend). Again, not in the book

  19. Simple Exp Smoothing • We’ll refer to the level of a series at time t as Lt for a given smoothing constant α: • A the future forecast for any time t+k • Note • Levels are defined recursively • All future forecasts are just the last level (or smoothed) value.

  20. Simple Exp Smoothing • From the previous equations it follows that the predicted level at any time t is just a function of the previous observed amounts: • What value of α should you use? • Eh… hard to stay. 0.1? 0.2? • Lower is smoother. (the weights in the book w, are 1-α and hence larger w produce smoother forecasts). • You can let StatTools optimize α to minimize RSME • Keep in mind that this could run the risk of overfitting your data

  21. Holt’s Method • If there is an obvious trend in the data, the simple exponential method doesn’t always do that well. A second method is due to Holt: Where Tt is the trend term at time t with a trend smoothing constant

  22. Question • What is the RMSE of a exponential smoothed forecast using Holt’s method with α=β=.2? (new_orders.xls) • 3.764 • 4.515 • 4.428 • 4.48

  23. Next time • Seasonally adjusting data • In practice, we usually don’t do it by hand but it’s important to know what’s going on • Later, we’ll leave the data and model seasonality directly • Winters’ method to smooth and adjust for seasonality. • Polynomial regressions

More Related