Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over...
Transcript of Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over...
![Page 1: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/1.jpg)
1
Rob J Hyndman
Automatic time seriesforecasting
![Page 2: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/2.jpg)
Outline
1 Motivation
2 Forecasting competitions
3 Evaluating forecast accuracy
4 Exponential smoothing
5 ARIMA modelling
6 Automatic nonlinear forecasting?
7 Time series with complex seasonality
8 Forecasts about automatic forecasting
Automatic time series forecasting Motivation 2
![Page 3: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/3.jpg)
Motivation
Automatic time series forecasting Motivation 3
![Page 4: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/4.jpg)
Motivation
Automatic time series forecasting Motivation 3
![Page 5: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/5.jpg)
Motivation
Automatic time series forecasting Motivation 3
![Page 6: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/6.jpg)
Motivation
Automatic time series forecasting Motivation 3
![Page 7: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/7.jpg)
Motivation
Automatic time series forecasting Motivation 3
![Page 8: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/8.jpg)
Motivation
1 Common in business to have over 1000products that need forecasting at least monthly.
2 Forecasts are often required by people who areuntrained in time series analysis.
Specifications
Automatic forecasting algorithms must:
å determine an appropriate time series model;
å estimate the parameters;
å compute the forecasts with prediction intervals.
Automatic time series forecasting Motivation 4
![Page 9: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/9.jpg)
Motivation
1 Common in business to have over 1000products that need forecasting at least monthly.
2 Forecasts are often required by people who areuntrained in time series analysis.
Specifications
Automatic forecasting algorithms must:
å determine an appropriate time series model;
å estimate the parameters;
å compute the forecasts with prediction intervals.
Automatic time series forecasting Motivation 4
![Page 10: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/10.jpg)
Example: Asian sheep
Automatic time series forecasting Motivation 5
Numbers of sheep in Asia
Year
mill
ions
of s
heep
1960 1970 1980 1990 2000 2010
250
300
350
400
450
500
550
![Page 11: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/11.jpg)
Example: Asian sheep
Automatic time series forecasting Motivation 5
Automatic ETS forecasts
Year
mill
ions
of s
heep
1960 1970 1980 1990 2000 2010
250
300
350
400
450
500
550
![Page 12: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/12.jpg)
Example: Cortecosteroid sales
Automatic time series forecasting Motivation 6
Monthly cortecosteroid drug sales in Australia
Year
Tota
l scr
ipts
(m
illio
ns)
1995 2000 2005 2010
0.4
0.6
0.8
1.0
1.2
1.4
![Page 13: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/13.jpg)
Example: Cortecosteroid sales
Automatic time series forecasting Motivation 6
Automatic ARIMA forecasts
Year
Tota
l scr
ipts
(m
illio
ns)
1995 2000 2005 2010
0.4
0.6
0.8
1.0
1.2
1.4
![Page 14: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/14.jpg)
Outline
1 Motivation
2 Forecasting competitions
3 Evaluating forecast accuracy
4 Exponential smoothing
5 ARIMA modelling
6 Automatic nonlinear forecasting?
7 Time series with complex seasonality
8 Forecasts about automatic forecasting
Automatic time series forecasting Forecasting competitions 7
![Page 15: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/15.jpg)
Makridakis and Hibon (1979)
Automatic time series forecasting Forecasting competitions 8
![Page 16: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/16.jpg)
Makridakis and Hibon (1979)
Automatic time series forecasting Forecasting competitions 8
![Page 17: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/17.jpg)
Makridakis and Hibon (1979)
This was the first large-scale empirical evaluation oftime series forecasting methods.
Highly controversial at the time.
Difficulties:8 How to measure forecast accuracy?8 How to apply methods consistently and objectively?8 How to explain unexpected results?
Common thinking was that the moresophisticated mathematical models (ARIMAmodels at the time) were necessarily better.If results showed ARIMA models not best, itmust be because analyst was unskilled.Automatic time series forecasting Forecasting competitions 9
![Page 18: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/18.jpg)
Makridakis and Hibon (1979)
I do not believe that it is very fruitful to attempt toclassify series according to which forecasting techniquesperform “best”. The performance of any particulartechnique when applied to a particular series dependsessentially on (a) the model which the series obeys;(b) our ability to identify and fit this model correctly and(c) the criterion chosen to measure the forecastingaccuracy. — M.B. Priestley
. . . the paper suggests the application of normal scientificexperimental design to forecasting, with measures ofunbiased testing of forecasts against subsequent reality,for success or failure. A long overdue reform.
— F.H. Hansford-Miller
Automatic time series forecasting Forecasting competitions 10
![Page 19: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/19.jpg)
Makridakis and Hibon (1979)
I do not believe that it is very fruitful to attempt toclassify series according to which forecasting techniquesperform “best”. The performance of any particulartechnique when applied to a particular series dependsessentially on (a) the model which the series obeys;(b) our ability to identify and fit this model correctly and(c) the criterion chosen to measure the forecastingaccuracy. — M.B. Priestley
. . . the paper suggests the application of normal scientificexperimental design to forecasting, with measures ofunbiased testing of forecasts against subsequent reality,for success or failure. A long overdue reform.
— F.H. Hansford-Miller
Automatic time series forecasting Forecasting competitions 10
![Page 20: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/20.jpg)
Makridakis and Hibon (1979)
Modern man is fascinated with the subject offorecasting — W.G. Gilchrist
It is amazing to me, however, that after all thisexercise in identifying models, transforming and soon, that the autoregressive moving averages comeout so badly. I wonder whether it might be partlydue to the authors not using the backwardsforecasting approach to obtain the initial errors.
— W.G. Gilchrist
Automatic time series forecasting Forecasting competitions 11
![Page 21: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/21.jpg)
Makridakis and Hibon (1979)
Modern man is fascinated with the subject offorecasting — W.G. Gilchrist
It is amazing to me, however, that after all thisexercise in identifying models, transforming and soon, that the autoregressive moving averages comeout so badly. I wonder whether it might be partlydue to the authors not using the backwardsforecasting approach to obtain the initial errors.
— W.G. Gilchrist
Automatic time series forecasting Forecasting competitions 11
![Page 22: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/22.jpg)
Makridakis and Hibon (1979)
I find it hard to believe that Box-Jenkins, if properlyapplied, can actually be worse than so many of thesimple methods — C. Chatfield
Why do empirical studies sometimes give differentanswers? It may depend on the selected sample oftime series, but I suspect it is more likely to dependon the skill of the analyst and on their individualinterpretations of what is meant by Method X.
— C. Chatfield
. . . these authors are more at home with simpleprocedures than with Box-Jenkins. — C. Chatfield
Automatic time series forecasting Forecasting competitions 12
![Page 23: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/23.jpg)
Makridakis and Hibon (1979)
I find it hard to believe that Box-Jenkins, if properlyapplied, can actually be worse than so many of thesimple methods — C. Chatfield
Why do empirical studies sometimes give differentanswers? It may depend on the selected sample oftime series, but I suspect it is more likely to dependon the skill of the analyst and on their individualinterpretations of what is meant by Method X.
— C. Chatfield
. . . these authors are more at home with simpleprocedures than with Box-Jenkins. — C. Chatfield
Automatic time series forecasting Forecasting competitions 12
![Page 24: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/24.jpg)
Makridakis and Hibon (1979)
I find it hard to believe that Box-Jenkins, if properlyapplied, can actually be worse than so many of thesimple methods — C. Chatfield
Why do empirical studies sometimes give differentanswers? It may depend on the selected sample oftime series, but I suspect it is more likely to dependon the skill of the analyst and on their individualinterpretations of what is meant by Method X.
— C. Chatfield
. . . these authors are more at home with simpleprocedures than with Box-Jenkins. — C. Chatfield
Automatic time series forecasting Forecasting competitions 12
![Page 25: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/25.jpg)
Makridakis and Hibon (1979)
There is a fact that Professor Priestley must accept:empirical evidence is in disagreement with histheoretical arguments. — S. Makridakis & M. Hibon
Dr Chatfield expresses some personal views aboutthe first author . . . It might be useful for Dr Chatfieldto read some of the psychological literature quotedin the main paper, and he can then learn a littlemore about biases and how they affect priorprobabilities. — S. Makridakis & M. Hibon
Automatic time series forecasting Forecasting competitions 13
![Page 26: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/26.jpg)
Makridakis and Hibon (1979)
There is a fact that Professor Priestley must accept:empirical evidence is in disagreement with histheoretical arguments. — S. Makridakis & M. Hibon
Dr Chatfield expresses some personal views aboutthe first author . . . It might be useful for Dr Chatfieldto read some of the psychological literature quotedin the main paper, and he can then learn a littlemore about biases and how they affect priorprobabilities. — S. Makridakis & M. Hibon
Automatic time series forecasting Forecasting competitions 13
![Page 27: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/27.jpg)
Consequences of M&H (1979)
As a result of this paper, researchers started to:
å consider how to automate forecasting methods;
å study what methods give the best forecasts;
å be aware of the dangers of over-fitting;
å treat forecasting as a different problem fromtime series analysis.
Makridakis & Hibon followed up with a newcompetition in 1982:
1001 seriesAnyone could submit forecasts (avoiding thecharge of incompetence)Multiple forecast measures used.Automatic time series forecasting Forecasting competitions 14
![Page 28: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/28.jpg)
Consequences of M&H (1979)
As a result of this paper, researchers started to:
å consider how to automate forecasting methods;
å study what methods give the best forecasts;
å be aware of the dangers of over-fitting;
å treat forecasting as a different problem fromtime series analysis.
Makridakis & Hibon followed up with a newcompetition in 1982:
1001 seriesAnyone could submit forecasts (avoiding thecharge of incompetence)Multiple forecast measures used.Automatic time series forecasting Forecasting competitions 14
![Page 29: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/29.jpg)
M-competition
Automatic time series forecasting Forecasting competitions 15
![Page 30: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/30.jpg)
M-competition
Main findings (taken from Makridakis & Hibon, 2000)
1 Statistically sophisticated or complex methods donot necessarily provide more accurate forecaststhan simpler ones.
2 The relative ranking of the performance of thevarious methods varies according to the accuracymeasure being used.
3 The accuracy when various methods are beingcombined outperforms, on average, the individualmethods being combined and does very well incomparison to other methods.
4 The accuracy of the various methods depends uponthe length of the forecasting horizon involved.
Automatic time series forecasting Forecasting competitions 16
![Page 31: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/31.jpg)
M3 competition
Automatic time series forecasting Forecasting competitions 17
![Page 32: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/32.jpg)
Makridakis and Hibon (2000)
“The M3-Competition is a final attempt by the authors tosettle the accuracy issue of various time series methods. . .The extension involves the inclusion of more methods/researchers (in particular in the areas of neural networksand expert systems) and more series.”
3003 seriesAll data from business, demography, finance andeconomics.Series length between 14 and 126.Either non-seasonal, monthly or quarterly.All time series positive.M&H claimed that the M3-competition supported thefindings of their earlier work.However, best performing methods far from “simple”.Automatic time series forecasting Forecasting competitions 18
![Page 33: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/33.jpg)
Makridakis and Hibon (2000)Best methods:
Theta
A very confusing explanation.
Shown by Hyndman and Billah (2003) to be average oflinear regression and simple exponential smoothingwith drift, applied to seasonally adjusted data.
Later, the original authors claimed that theirexplanation was incorrect.
Forecast Pro
A commercial software package with an unknownalgorithm.
Known to fit either exponential smoothing or ARIMAmodels using BIC.
Automatic time series forecasting Forecasting competitions 19
![Page 34: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/34.jpg)
M3 results (recalculated)
Method MAPE sMAPE MASE
Theta 17.42 12.76 1.39
ForecastPro 18.00 13.06 1.47
ForecastX 17.35 13.09 1.42
Automatic ANN 17.18 13.98 1.53
B-J automatic 19.13 13.72 1.54
Automatic time series forecasting Forecasting competitions 20
![Page 35: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/35.jpg)
M3 results (recalculated)
Method MAPE sMAPE MASE
Theta 17.42 12.76 1.39
ForecastPro 18.00 13.06 1.47
ForecastX 17.35 13.09 1.42
Automatic ANN 17.18 13.98 1.53
B-J automatic 19.13 13.72 1.54
Automatic time series forecasting Forecasting competitions 20
ä Calculations do not match
published paper.
ä Some contestants apparently
submitted multiple entries but only
best ones published.
![Page 36: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/36.jpg)
Outline
1 Motivation
2 Forecasting competitions
3 Evaluating forecast accuracy
4 Exponential smoothing
5 ARIMA modelling
6 Automatic nonlinear forecasting?
7 Time series with complex seasonality
8 Forecasts about automatic forecasting
Automatic time series forecasting Evaluating forecast accuracy 21
![Page 37: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/37.jpg)
Cross-validationTraditional evaluation
Automatic time series forecasting Evaluating forecast accuracy 22
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● timeTraining data Test data
![Page 38: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/38.jpg)
Cross-validationTraditional evaluation
Standard cross-validation
Automatic time series forecasting Evaluating forecast accuracy 22
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● timeTraining data Test data
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ●●● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ●● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●●●● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●● ●●●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ● ● ●●
![Page 39: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/39.jpg)
Cross-validationTraditional evaluation
Standard cross-validation
Time series cross-validation
Automatic time series forecasting Evaluating forecast accuracy 22
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● timeTraining data Test data
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ●●● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ●● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●●●● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●● ●●●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ● ● ●●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
![Page 40: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/40.jpg)
Cross-validationTraditional evaluation
Standard cross-validation
Time series cross-validation
Automatic time series forecasting Evaluating forecast accuracy 22
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● timeTraining data Test data
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ●●● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ●● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●●●● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●● ●●●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ● ● ●●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
![Page 41: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/41.jpg)
Cross-validationTraditional evaluation
Standard cross-validation
Time series cross-validation
Automatic time series forecasting Evaluating forecast accuracy 22
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● timeTraining data Test data
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ●●● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ●● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●●●● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●● ●●●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ● ● ●●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●
Also known as “Evaluation ona rolling forecast origin”
![Page 42: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/42.jpg)
Akaike’s Information Criterion
AIC = −2 log(L) + 2k
where L is the likelihood and k is the number ofestimated parameters in the model.
This is a penalized likelihood approach.If L is Gaussian, then AIC ≈ c + T log MSE + 2kwhere c is a constant, MSE is from one-stepforecasts on training set, and T is the length ofthe series.
Minimizing the Gaussian AIC is asymptoticallyequivalent (as T →∞) to minimizing MSE fromone-step forecasts on test set via time seriescross-validation.
Automatic time series forecasting Evaluating forecast accuracy 23
![Page 43: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/43.jpg)
Akaike’s Information Criterion
AIC = −2 log(L) + 2k
where L is the likelihood and k is the number ofestimated parameters in the model.
This is a penalized likelihood approach.If L is Gaussian, then AIC ≈ c + T log MSE + 2kwhere c is a constant, MSE is from one-stepforecasts on training set, and T is the length ofthe series.
Minimizing the Gaussian AIC is asymptoticallyequivalent (as T →∞) to minimizing MSE fromone-step forecasts on test set via time seriescross-validation.
Automatic time series forecasting Evaluating forecast accuracy 23
![Page 44: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/44.jpg)
Akaike’s Information Criterion
AIC = −2 log(L) + 2k
where L is the likelihood and k is the number ofestimated parameters in the model.
This is a penalized likelihood approach.If L is Gaussian, then AIC ≈ c + T log MSE + 2kwhere c is a constant, MSE is from one-stepforecasts on training set, and T is the length ofthe series.
Minimizing the Gaussian AIC is asymptoticallyequivalent (as T →∞) to minimizing MSE fromone-step forecasts on test set via time seriescross-validation.
Automatic time series forecasting Evaluating forecast accuracy 23
![Page 45: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/45.jpg)
Akaike’s Information Criterion
AIC = −2 log(L) + 2k
where L is the likelihood and k is the number ofestimated parameters in the model.
This is a penalized likelihood approach.If L is Gaussian, then AIC ≈ c + T log MSE + 2kwhere c is a constant, MSE is from one-stepforecasts on training set, and T is the length ofthe series.
Minimizing the Gaussian AIC is asymptoticallyequivalent (as T →∞) to minimizing MSE fromone-step forecasts on test set via time seriescross-validation.
Automatic time series forecasting Evaluating forecast accuracy 23
![Page 46: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/46.jpg)
Akaike’s Information Criterion
AIC = −2 log(L) + 2k
where L is the likelihood and k is the number ofestimated parameters in the model.
This is a penalized likelihood approach.If L is Gaussian, then AIC ≈ c + T log MSE + 2kwhere c is a constant, MSE is from one-stepforecasts on training set, and T is the length ofthe series.
Minimizing the Gaussian AIC is asymptoticallyequivalent (as T →∞) to minimizing MSE fromone-step forecasts on test set via time seriescross-validation.
Automatic time series forecasting Evaluating forecast accuracy 23
![Page 47: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/47.jpg)
Akaike’s Information Criterion
AIC = −2 log(L) + 2k
Corrected AICFor small T, AIC tends to over-fit. Bias-correctedversion:
AICC = AIC + 2(k+1)(k+2)T−k
Bayesian Information Criterion
BIC = AIC + k[log(T)− 2]
BIC penalizes terms more heavily than AICMinimizing BIC is consistent if there is a truemodel.Automatic time series forecasting Evaluating forecast accuracy 24
![Page 48: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/48.jpg)
Akaike’s Information Criterion
AIC = −2 log(L) + 2k
Corrected AICFor small T, AIC tends to over-fit. Bias-correctedversion:
AICC = AIC + 2(k+1)(k+2)T−k
Bayesian Information Criterion
BIC = AIC + k[log(T)− 2]
BIC penalizes terms more heavily than AICMinimizing BIC is consistent if there is a truemodel.Automatic time series forecasting Evaluating forecast accuracy 24
![Page 49: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/49.jpg)
Akaike’s Information Criterion
AIC = −2 log(L) + 2k
Corrected AICFor small T, AIC tends to over-fit. Bias-correctedversion:
AICC = AIC + 2(k+1)(k+2)T−k
Bayesian Information Criterion
BIC = AIC + k[log(T)− 2]
BIC penalizes terms more heavily than AICMinimizing BIC is consistent if there is a truemodel.Automatic time series forecasting Evaluating forecast accuracy 24
![Page 50: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/50.jpg)
What to use?
Choice: AIC, AICc, BIC, CV-MSE
CV-MSE too time consuming for most automaticforecasting purposes. Also requires large T.
As T →∞, BIC selects true model if there isone. But that is never true!
AICc focuses on forecasting performance, canbe used on small samples and is very fast tocompute.
Empirical studies in forecasting show AIC isbetter than BIC for forecast accuracy.
Automatic time series forecasting Evaluating forecast accuracy 25
![Page 51: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/51.jpg)
What to use?
Choice: AIC, AICc, BIC, CV-MSE
CV-MSE too time consuming for most automaticforecasting purposes. Also requires large T.
As T →∞, BIC selects true model if there isone. But that is never true!
AICc focuses on forecasting performance, canbe used on small samples and is very fast tocompute.
Empirical studies in forecasting show AIC isbetter than BIC for forecast accuracy.
Automatic time series forecasting Evaluating forecast accuracy 25
![Page 52: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/52.jpg)
What to use?
Choice: AIC, AICc, BIC, CV-MSE
CV-MSE too time consuming for most automaticforecasting purposes. Also requires large T.
As T →∞, BIC selects true model if there isone. But that is never true!
AICc focuses on forecasting performance, canbe used on small samples and is very fast tocompute.
Empirical studies in forecasting show AIC isbetter than BIC for forecast accuracy.
Automatic time series forecasting Evaluating forecast accuracy 25
![Page 53: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/53.jpg)
What to use?
Choice: AIC, AICc, BIC, CV-MSE
CV-MSE too time consuming for most automaticforecasting purposes. Also requires large T.
As T →∞, BIC selects true model if there isone. But that is never true!
AICc focuses on forecasting performance, canbe used on small samples and is very fast tocompute.
Empirical studies in forecasting show AIC isbetter than BIC for forecast accuracy.
Automatic time series forecasting Evaluating forecast accuracy 25
![Page 54: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/54.jpg)
What to use?
Choice: AIC, AICc, BIC, CV-MSE
CV-MSE too time consuming for most automaticforecasting purposes. Also requires large T.
As T →∞, BIC selects true model if there isone. But that is never true!
AICc focuses on forecasting performance, canbe used on small samples and is very fast tocompute.
Empirical studies in forecasting show AIC isbetter than BIC for forecast accuracy.
Automatic time series forecasting Evaluating forecast accuracy 25
![Page 55: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/55.jpg)
Outline
1 Motivation
2 Forecasting competitions
3 Evaluating forecast accuracy
4 Exponential smoothing
5 ARIMA modelling
6 Automatic nonlinear forecasting?
7 Time series with complex seasonality
8 Forecasts about automatic forecasting
Automatic time series forecasting Exponential smoothing 26
![Page 56: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/56.jpg)
Exponential smoothing
Automatic time series forecasting Exponential smoothing 27
![Page 57: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/57.jpg)
Exponential smoothing
Automatic time series forecasting Exponential smoothing 27
![Page 58: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/58.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
Automatic time series forecasting Exponential smoothing 28
![Page 59: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/59.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
N,N: Simple exponential smoothing
Automatic time series forecasting Exponential smoothing 28
![Page 60: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/60.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
N,N: Simple exponential smoothingA,N: Holt’s linear method
Automatic time series forecasting Exponential smoothing 28
![Page 61: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/61.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
N,N: Simple exponential smoothingA,N: Holt’s linear methodAd,N: Additive damped trend method
Automatic time series forecasting Exponential smoothing 28
![Page 62: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/62.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
N,N: Simple exponential smoothingA,N: Holt’s linear methodAd,N: Additive damped trend methodM,N: Exponential trend method
Automatic time series forecasting Exponential smoothing 28
![Page 63: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/63.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
N,N: Simple exponential smoothingA,N: Holt’s linear methodAd,N: Additive damped trend methodM,N: Exponential trend methodMd,N: Multiplicative damped trend method
Automatic time series forecasting Exponential smoothing 28
![Page 64: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/64.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
N,N: Simple exponential smoothingA,N: Holt’s linear methodAd,N: Additive damped trend methodM,N: Exponential trend methodMd,N: Multiplicative damped trend methodA,A: Additive Holt-Winters’ method
Automatic time series forecasting Exponential smoothing 28
![Page 65: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/65.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
N,N: Simple exponential smoothingA,N: Holt’s linear methodAd,N: Additive damped trend methodM,N: Exponential trend methodMd,N: Multiplicative damped trend methodA,A: Additive Holt-Winters’ methodA,M: Multiplicative Holt-Winters’ method
Automatic time series forecasting Exponential smoothing 28
![Page 66: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/66.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
There are 15 separate exponential smoothingmethods.
Automatic time series forecasting Exponential smoothing 28
![Page 67: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/67.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
There are 15 separate exponential smoothingmethods.Each can have an additive or multiplicative error,giving 30 separate models.
Automatic time series forecasting Exponential smoothing 28
![Page 68: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/68.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
There are 15 separate exponential smoothingmethods.Each can have an additive or multiplicative error,giving 30 separate models.Only 19 models are numerically stable.Automatic time series forecasting Exponential smoothing 28
![Page 69: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/69.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
General notation E T S : ExponenTial Smoothing
Examples:A,N,N: Simple exponential smoothing with additive errorsA,A,N: Holt’s linear method with additive errorsM,A,M: Multiplicative Holt-Winters’ method with multiplicative errors
Automatic time series forecasting Exponential smoothing 29
![Page 70: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/70.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
General notation E T S : ExponenTial Smoothing
Examples:A,N,N: Simple exponential smoothing with additive errorsA,A,N: Holt’s linear method with additive errorsM,A,M: Multiplicative Holt-Winters’ method with multiplicative errors
Automatic time series forecasting Exponential smoothing 29
![Page 71: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/71.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
General notation E T S : ExponenTial Smoothing↑
TrendExamples:
A,N,N: Simple exponential smoothing with additive errorsA,A,N: Holt’s linear method with additive errorsM,A,M: Multiplicative Holt-Winters’ method with multiplicative errors
Automatic time series forecasting Exponential smoothing 29
![Page 72: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/72.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
General notation E T S : ExponenTial Smoothing↑ ↖
Trend SeasonalExamples:
A,N,N: Simple exponential smoothing with additive errorsA,A,N: Holt’s linear method with additive errorsM,A,M: Multiplicative Holt-Winters’ method with multiplicative errors
Automatic time series forecasting Exponential smoothing 29
![Page 73: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/73.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
General notation E T S : ExponenTial Smoothing↗ ↑ ↖
Error Trend SeasonalExamples:
A,N,N: Simple exponential smoothing with additive errorsA,A,N: Holt’s linear method with additive errorsM,A,M: Multiplicative Holt-Winters’ method with multiplicative errors
Automatic time series forecasting Exponential smoothing 29
![Page 74: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/74.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
General notation E T S : ExponenTial Smoothing↗ ↑ ↖
Error Trend SeasonalExamples:
A,N,N: Simple exponential smoothing with additive errorsA,A,N: Holt’s linear method with additive errorsM,A,M: Multiplicative Holt-Winters’ method with multiplicative errors
Automatic time series forecasting Exponential smoothing 29
![Page 75: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/75.jpg)
Exponential smoothing methods
Seasonal ComponentTrend N A M
Component (None) (Additive) (Multiplicative)
N (None) N,N N,A N,M
A (Additive) A,N A,A A,M
Ad (Additive damped) Ad,N Ad,A Ad,M
M (Multiplicative) M,N M,A M,M
Md (Multiplicative damped) Md,N Md,A Md,M
General notation E T S : ExponenTial Smoothing↗ ↑ ↖
Error Trend SeasonalExamples:
A,N,N: Simple exponential smoothing with additive errorsA,A,N: Holt’s linear method with additive errorsM,A,M: Multiplicative Holt-Winters’ method with multiplicative errors
Automatic time series forecasting Exponential smoothing 29
Innovations state space models
å All ETS models can be written in innovationsstate space form (IJF, 2002).
å Additive and multiplicative versions give thesame point forecasts but different predictionintervals.
![Page 76: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/76.jpg)
Innovations state space models
Let xt = (`t,bt, st, st−1, . . . , st−m+1) and εtiid∼ N(0, σ2).
yt = h(xt−1)︸ ︷︷ ︸+ k(xt−1)εt︸ ︷︷ ︸ Observation equation
µt et
xt = f(xt−1) + g(xt−1)εt State equation
Additive errors:k(xt−1) = 1. yt = µt + εt.
Multiplicative errors:k(xt−1) = µt. yt = µt(1 + εt).
εt = (yt − µt)/µt is relative error.
Automatic time series forecasting Exponential smoothing 30
![Page 77: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/77.jpg)
Innovations state space models
All models can be written in state space form.
Additive and multiplicative versions give samepoint forecasts but different predictionintervals.
Estimation
L∗(θ,x0) = n log
( n∑t=1
ε2t /k
2(xt−1)
)+ 2
n∑t=1
log |k(xt−1)|
= −2 log(Likelihood) + constant
Minimize wrt θ = (α, β, γ, φ) and initial statesx0 = (`0,b0, s0, s−1, . . . , s−m+1).Automatic time series forecasting Exponential smoothing 31
![Page 78: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/78.jpg)
Innovations state space models
All models can be written in state space form.
Additive and multiplicative versions give samepoint forecasts but different predictionintervals.
Estimation
L∗(θ,x0) = n log
( n∑t=1
ε2t /k
2(xt−1)
)+ 2
n∑t=1
log |k(xt−1)|
= −2 log(Likelihood) + constant
Minimize wrt θ = (α, β, γ, φ) and initial statesx0 = (`0,b0, s0, s−1, . . . , s−m+1).Automatic time series forecasting Exponential smoothing 31
![Page 79: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/79.jpg)
Innovations state space models
All models can be written in state space form.
Additive and multiplicative versions give samepoint forecasts but different predictionintervals.
Estimation
L∗(θ,x0) = n log
( n∑t=1
ε2t /k
2(xt−1)
)+ 2
n∑t=1
log |k(xt−1)|
= −2 log(Likelihood) + constant
Minimize wrt θ = (α, β, γ, φ) and initial statesx0 = (`0,b0, s0, s−1, . . . , s−m+1).Automatic time series forecasting Exponential smoothing 31
![Page 80: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/80.jpg)
Innovations state space models
All models can be written in state space form.
Additive and multiplicative versions give samepoint forecasts but different predictionintervals.
Estimation
L∗(θ,x0) = n log
( n∑t=1
ε2t /k
2(xt−1)
)+ 2
n∑t=1
log |k(xt−1)|
= −2 log(Likelihood) + constant
Minimize wrt θ = (α, β, γ, φ) and initial statesx0 = (`0,b0, s0, s−1, . . . , s−m+1).Automatic time series forecasting Exponential smoothing 31
![Page 81: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/81.jpg)
Innovations state space models
All models can be written in state space form.
Additive and multiplicative versions give samepoint forecasts but different predictionintervals.
Estimation
L∗(θ,x0) = n log
( n∑t=1
ε2t /k
2(xt−1)
)+ 2
n∑t=1
log |k(xt−1)|
= −2 log(Likelihood) + constant
Minimize wrt θ = (α, β, γ, φ) and initial statesx0 = (`0,b0, s0, s−1, . . . , s−m+1).Automatic time series forecasting Exponential smoothing 31
![Page 82: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/82.jpg)
ets algorithm in R
Automatic time series forecasting Exponential smoothing 32
Based on Hyndman & Khandakar(IJF 2008):
Apply each of 19 models that areappropriate to the data. Optimizeparameters and initial valuesusing MLE.
Select best method using AICc.
Produce forecasts using bestmethod.
Obtain prediction intervals usingunderlying state space model.
![Page 83: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/83.jpg)
ets algorithm in R
Automatic time series forecasting Exponential smoothing 32
Based on Hyndman & Khandakar(IJF 2008):
Apply each of 19 models that areappropriate to the data. Optimizeparameters and initial valuesusing MLE.
Select best method using AICc.
Produce forecasts using bestmethod.
Obtain prediction intervals usingunderlying state space model.
![Page 84: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/84.jpg)
ets algorithm in R
Automatic time series forecasting Exponential smoothing 32
Based on Hyndman & Khandakar(IJF 2008):
Apply each of 19 models that areappropriate to the data. Optimizeparameters and initial valuesusing MLE.
Select best method using AICc.
Produce forecasts using bestmethod.
Obtain prediction intervals usingunderlying state space model.
![Page 85: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/85.jpg)
ets algorithm in R
Automatic time series forecasting Exponential smoothing 32
Based on Hyndman & Khandakar(IJF 2008):
Apply each of 19 models that areappropriate to the data. Optimizeparameters and initial valuesusing MLE.
Select best method using AICc.
Produce forecasts using bestmethod.
Obtain prediction intervals usingunderlying state space model.
![Page 86: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/86.jpg)
Exponential smoothing
Automatic time series forecasting Exponential smoothing 33
Forecasts from ETS(M,A,N)
Year
mill
ions
of s
heep
1960 1970 1980 1990 2000 2010
300
400
500
600
![Page 87: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/87.jpg)
Exponential smoothing
fit <- ets(livestock)fcast <- forecast(fit)plot(fcast)
Automatic time series forecasting Exponential smoothing 34
Forecasts from ETS(M,A,N)
Year
mill
ions
of s
heep
1960 1970 1980 1990 2000 2010
300
400
500
600
![Page 88: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/88.jpg)
Exponential smoothing
Automatic time series forecasting Exponential smoothing 35
Forecasts from ETS(M,Md,M)
Year
Tota
l scr
ipts
(m
illio
ns)
1995 2000 2005 2010
0.4
0.6
0.8
1.0
1.2
1.4
1.6
![Page 89: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/89.jpg)
Exponential smoothing
fit <- ets(h02)fcast <- forecast(fit)plot(fcast)
Automatic time series forecasting Exponential smoothing 36
Forecasts from ETS(M,Md,M)
Year
Tota
l scr
ipts
(m
illio
ns)
1995 2000 2005 2010
0.4
0.6
0.8
1.0
1.2
1.4
1.6
![Page 90: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/90.jpg)
M3 comparisons
Method MAPE sMAPE MASE
Theta 17.42 12.76 1.39
ForecastPro 18.00 13.06 1.47
ForecastX 17.35 13.09 1.42
Automatic ANN 17.18 13.98 1.53
B-J automatic 19.13 13.72 1.54
ETS 18.06 13.38 1.52
Automatic time series forecasting Exponential smoothing 37
![Page 91: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/91.jpg)
Outline
1 Motivation
2 Forecasting competitions
3 Evaluating forecast accuracy
4 Exponential smoothing
5 ARIMA modelling
6 Automatic nonlinear forecasting?
7 Time series with complex seasonality
8 Forecasts about automatic forecasting
Automatic time series forecasting ARIMA modelling 38
![Page 92: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/92.jpg)
ARIMA modelling
A non-seasonal ARIMA process
φ(B)(1− B)dyt = c + θ(B)εt
B is backshift operator and εt is (Gaussian) iid noise.
A seasonal ARIMA process (period m)
Φ(Bm)φ(B)(1− B)d(1− Bm)Dyt = c + Θ(Bm)θ(B)εt
−2× Log likelihood function
L∗(β) = f(β) + T logσ2 +1
σ2
T∑t=1
(yt − yt|t−1)2/rt(β)
where β contains all parameters to be estimatedand σ2 is variance of {εt}.
Automatic time series forecasting ARIMA modelling 39
![Page 93: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/93.jpg)
ARIMA modelling
Automatic time series forecasting ARIMA modelling 40
![Page 94: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/94.jpg)
ARIMA modelling
Automatic time series forecasting ARIMA modelling 40
![Page 95: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/95.jpg)
ARIMA modelling
Automatic time series forecasting ARIMA modelling 40
![Page 96: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/96.jpg)
Auto ARIMA
Automatic time series forecasting ARIMA modelling 41
Forecasts from ARIMA(0,1,0) with drift
Year
mill
ions
of s
heep
1960 1970 1980 1990 2000 2010
250
300
350
400
450
500
550
![Page 97: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/97.jpg)
Auto ARIMA
fit <- auto.arima(livestock)fcast <- forecast(fit)plot(fcast)
Automatic time series forecasting ARIMA modelling 42
Forecasts from ARIMA(0,1,0) with drift
Year
mill
ions
of s
heep
1960 1970 1980 1990 2000 2010
250
300
350
400
450
500
550
![Page 98: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/98.jpg)
Auto ARIMA
Automatic time series forecasting ARIMA modelling 43
Forecasts from ARIMA(3,1,3)(0,1,1)[12]
Year
Tota
l scr
ipts
(m
illio
ns)
1995 2000 2005 2010
0.4
0.6
0.8
1.0
1.2
1.4
![Page 99: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/99.jpg)
Auto ARIMA
fit <- auto.arima(h02)fcast <- forecast(fit)plot(fcast)
Automatic time series forecasting ARIMA modelling 44
Forecasts from ARIMA(3,1,3)(0,1,1)[12]
Year
Tota
l scr
ipts
(m
illio
ns)
1995 2000 2005 2010
0.4
0.6
0.8
1.0
1.2
1.4
![Page 100: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/100.jpg)
How does auto.arima() work?
A non-seasonal ARIMA process
φ(B)(1− B)dyt = c + θ(B)εt
Need to select appropriate orders p,q,d, andwhether to include c.
Automatic time series forecasting ARIMA modelling 45
Algorithm choices driven by forecast accuracy.
![Page 101: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/101.jpg)
How does auto.arima() work?
A non-seasonal ARIMA process
φ(B)(1− B)dyt = c + θ(B)εt
Need to select appropriate orders p,q,d, andwhether to include c.
Hyndman & Khandakar (JSS, 2008) algorithm:Select no. differences d via KPSS unit root test.Select p,q, c by minimising AICc.Use stepwise search to traverse model space,starting with a simple model and consideringnearby variants.
Automatic time series forecasting ARIMA modelling 45
Algorithm choices driven by forecast accuracy.
![Page 102: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/102.jpg)
How does auto.arima() work?
A non-seasonal ARIMA process
φ(B)(1− B)dyt = c + θ(B)εt
Need to select appropriate orders p,q,d, andwhether to include c.
Hyndman & Khandakar (JSS, 2008) algorithm:Select no. differences d via KPSS unit root test.Select p,q, c by minimising AICc.Use stepwise search to traverse model space,starting with a simple model and consideringnearby variants.
Automatic time series forecasting ARIMA modelling 45
Algorithm choices driven by forecast accuracy.
![Page 103: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/103.jpg)
How does auto.arima() work?
A seasonal ARIMA process
Φ(Bm)φ(B)(1− B)d(1− Bm)Dyt = c + Θ(Bm)θ(B)εt
Need to select appropriate orders p,q,d, P,Q,D, andwhether to include c.
Hyndman & Khandakar (JSS, 2008) algorithm:Select no. differences d via KPSS unit root test.Select D using OCSB unit root test.Select p,q, P,Q, c by minimising AIC.Use stepwise search to traverse model space,starting with a simple model and consideringnearby variants.
Automatic time series forecasting ARIMA modelling 46
![Page 104: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/104.jpg)
M3 comparisons
Method MAPE sMAPE MASE
Theta 17.42 12.76 1.39
ForecastPro 18.00 13.06 1.47
B-J automatic 19.13 13.72 1.54
ETS 18.06 13.38 1.52
AutoARIMA 19.04 13.86 1.47
Automatic time series forecasting ARIMA modelling 47
![Page 105: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/105.jpg)
M3 comparisons
Method MAPE sMAPE MASE
Theta 17.42 12.76 1.39
ForecastPro 18.00 13.06 1.47
B-J automatic 19.13 13.72 1.54
ETS 18.06 13.38 1.52
AutoARIMA 19.04 13.86 1.47
ETS-ARIMA 17.92 13.02 1.44
Automatic time series forecasting ARIMA modelling 47
![Page 106: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/106.jpg)
M3 conclusions
MYTHS
Simple methods do better.
Exponential smoothing is better than ARIMA.
FACTS
The best methods are hybrid approaches.
ETS-ARIMA (the simple average of ETS-additiveand AutoARIMA) is the only fully documentedmethod that is comparable to the M3competition winners.
Automatic time series forecasting ARIMA modelling 48
![Page 107: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/107.jpg)
M3 conclusions
MYTHS
Simple methods do better.
Exponential smoothing is better than ARIMA.
FACTS
The best methods are hybrid approaches.
ETS-ARIMA (the simple average of ETS-additiveand AutoARIMA) is the only fully documentedmethod that is comparable to the M3competition winners.
Automatic time series forecasting ARIMA modelling 48
![Page 108: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/108.jpg)
M3 conclusions
MYTHS
Simple methods do better.
Exponential smoothing is better than ARIMA.
FACTS
The best methods are hybrid approaches.
ETS-ARIMA (the simple average of ETS-additiveand AutoARIMA) is the only fully documentedmethod that is comparable to the M3competition winners.
Automatic time series forecasting ARIMA modelling 48
![Page 109: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/109.jpg)
M3 conclusions
MYTHS
Simple methods do better.
Exponential smoothing is better than ARIMA.
FACTS
The best methods are hybrid approaches.
ETS-ARIMA (the simple average of ETS-additiveand AutoARIMA) is the only fully documentedmethod that is comparable to the M3competition winners.
Automatic time series forecasting ARIMA modelling 48
![Page 110: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/110.jpg)
M3 conclusions
MYTHS
Simple methods do better.
Exponential smoothing is better than ARIMA.
FACTS
The best methods are hybrid approaches.
ETS-ARIMA (the simple average of ETS-additiveand AutoARIMA) is the only fully documentedmethod that is comparable to the M3competition winners.
Automatic time series forecasting ARIMA modelling 48
![Page 111: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/111.jpg)
Outline
1 Motivation
2 Forecasting competitions
3 Evaluating forecast accuracy
4 Exponential smoothing
5 ARIMA modelling
6 Automatic nonlinear forecasting?
7 Time series with complex seasonality
8 Forecasts about automatic forecasting
Automatic time series forecasting Automatic nonlinear forecasting? 49
![Page 112: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/112.jpg)
Automatic nonlinear forecasting
Automatic ANN in M3 competition did poorly.
Linear methods did best in the NN3competition!Very few machine learning methods getpublished in the IJF because authors cannotdemonstrate their methods give betterforecasts than linear benchmark methods,even on supposedly nonlinear data.
Some good recent work by Kourentzes andCrone (Neurocomputing, 2010) on automatedANN for time series.Watch this space!Automatic time series forecasting Automatic nonlinear forecasting? 50
![Page 113: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/113.jpg)
Automatic nonlinear forecasting
Automatic ANN in M3 competition did poorly.
Linear methods did best in the NN3competition!
Very few machine learning methods getpublished in the IJF because authors cannotdemonstrate their methods give betterforecasts than linear benchmark methods,even on supposedly nonlinear data.
Some good recent work by Kourentzes andCrone (Neurocomputing, 2010) on automatedANN for time series.Watch this space!Automatic time series forecasting Automatic nonlinear forecasting? 50
![Page 114: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/114.jpg)
Automatic nonlinear forecasting
Automatic ANN in M3 competition did poorly.
Linear methods did best in the NN3competition!
Very few machine learning methods getpublished in the IJF because authors cannotdemonstrate their methods give betterforecasts than linear benchmark methods,even on supposedly nonlinear data.
Some good recent work by Kourentzes andCrone (Neurocomputing, 2010) on automatedANN for time series.Watch this space!Automatic time series forecasting Automatic nonlinear forecasting? 50
![Page 115: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/115.jpg)
Automatic nonlinear forecasting
Automatic ANN in M3 competition did poorly.
Linear methods did best in the NN3competition!
Very few machine learning methods getpublished in the IJF because authors cannotdemonstrate their methods give betterforecasts than linear benchmark methods,even on supposedly nonlinear data.
Some good recent work by Kourentzes andCrone (Neurocomputing, 2010) on automatedANN for time series.Watch this space!Automatic time series forecasting Automatic nonlinear forecasting? 50
![Page 116: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/116.jpg)
Automatic nonlinear forecasting
Automatic ANN in M3 competition did poorly.
Linear methods did best in the NN3competition!
Very few machine learning methods getpublished in the IJF because authors cannotdemonstrate their methods give betterforecasts than linear benchmark methods,even on supposedly nonlinear data.
Some good recent work by Kourentzes andCrone (Neurocomputing, 2010) on automatedANN for time series.Watch this space!Automatic time series forecasting Automatic nonlinear forecasting? 50
![Page 117: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/117.jpg)
Outline
1 Motivation
2 Forecasting competitions
3 Evaluating forecast accuracy
4 Exponential smoothing
5 ARIMA modelling
6 Automatic nonlinear forecasting?
7 Time series with complex seasonality
8 Forecasts about automatic forecasting
Automatic time series forecasting Time series with complex seasonality 51
![Page 118: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/118.jpg)
Examples
Automatic time series forecasting Time series with complex seasonality 52
US finished motor gasoline products
Weeks
Tho
usan
ds o
f bar
rels
per
day
1992 1994 1996 1998 2000 2002 2004
6500
7000
7500
8000
8500
9000
9500
![Page 119: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/119.jpg)
Examples
Automatic time series forecasting Time series with complex seasonality 52
Number of calls to large American bank (7am−9pm)
5 minute intervals
Num
ber
of c
all a
rriv
als
100
200
300
400
3 March 17 March 31 March 14 April 28 April 12 May
![Page 120: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/120.jpg)
Examples
Automatic time series forecasting Time series with complex seasonality 52
Turkish electricity demand
Days
Ele
ctric
ity d
eman
d (G
W)
2000 2002 2004 2006 2008
1015
2025
![Page 121: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/121.jpg)
TBATS model
TBATSTrigonometric terms for seasonality
Box-Cox transformations for heterogeneity
ARMA errors for short-term dynamics
Trend (possibly damped)
Seasonal (including multiple and non-integer periods)
Automatic algorithm described in AM De Livera,RJ Hyndman, and RD Snyder (2011). “Forecastingtime series with complex seasonal patterns usingexponential smoothing”. Journal of the AmericanStatistical Association 106(496), 1513–1527.
Automatic time series forecasting Time series with complex seasonality 53
![Page 122: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/122.jpg)
Examples
fit <- tbats(gasoline)fcast <- forecast(fit)plot(fcast)
Automatic time series forecasting Time series with complex seasonality 54
Forecasts from TBATS(0.999, {2,2}, 1, {<52.1785714285714,8>})
Weeks
Tho
usan
ds o
f bar
rels
per
day
1995 2000 2005
7000
8000
9000
1000
0
![Page 123: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/123.jpg)
Examples
fit <- tbats(callcentre)fcast <- forecast(fit)plot(fcast)
Automatic time series forecasting Time series with complex seasonality 55
Forecasts from TBATS(1, {3,1}, 0.987, {<169,5>, <845,3>})
5 minute intervals
Num
ber
of c
all a
rriv
als
010
020
030
040
050
0
3 March 17 March 31 March 14 April 28 April 12 May 26 May 9 June
![Page 124: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/124.jpg)
Examples
fit <- tbats(turk)fcast <- forecast(fit)plot(fcast)
Automatic time series forecasting Time series with complex seasonality 56
Forecasts from TBATS(0, {5,3}, 0.997, {<7,3>, <354.37,12>, <365.25,4>})
Days
Ele
ctric
ity d
eman
d (G
W)
2000 2002 2004 2006 2008 2010
1015
2025
![Page 125: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/125.jpg)
Outline
1 Motivation
2 Forecasting competitions
3 Evaluating forecast accuracy
4 Exponential smoothing
5 ARIMA modelling
6 Automatic nonlinear forecasting?
7 Time series with complex seasonality
8 Forecasts about automatic forecasting
Automatic time series forecasting Forecasts about automatic forecasting 57
![Page 126: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/126.jpg)
Forecasts about forecasting
1 Automatic algorithms will become moregeneral — handling a wide variety of timeseries.
2 Model selection methods will take accountof multi-step forecast accuracy as well asone-step forecast accuracy.
3 Automatic forecasting algorithms formultivariate time series will be developed.
4 Automatic forecasting algorithms thatinclude covariate information will bedeveloped.
Automatic time series forecasting Forecasts about automatic forecasting 58
![Page 127: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/127.jpg)
Forecasts about forecasting
1 Automatic algorithms will become moregeneral — handling a wide variety of timeseries.
2 Model selection methods will take accountof multi-step forecast accuracy as well asone-step forecast accuracy.
3 Automatic forecasting algorithms formultivariate time series will be developed.
4 Automatic forecasting algorithms thatinclude covariate information will bedeveloped.
Automatic time series forecasting Forecasts about automatic forecasting 58
![Page 128: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/128.jpg)
Forecasts about forecasting
1 Automatic algorithms will become moregeneral — handling a wide variety of timeseries.
2 Model selection methods will take accountof multi-step forecast accuracy as well asone-step forecast accuracy.
3 Automatic forecasting algorithms formultivariate time series will be developed.
4 Automatic forecasting algorithms thatinclude covariate information will bedeveloped.
Automatic time series forecasting Forecasts about automatic forecasting 58
![Page 129: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/129.jpg)
Forecasts about forecasting
1 Automatic algorithms will become moregeneral — handling a wide variety of timeseries.
2 Model selection methods will take accountof multi-step forecast accuracy as well asone-step forecast accuracy.
3 Automatic forecasting algorithms formultivariate time series will be developed.
4 Automatic forecasting algorithms thatinclude covariate information will bedeveloped.
Automatic time series forecasting Forecasts about automatic forecasting 58
![Page 130: Automatic time series forecasting - Rob J Hyndman · Motivation 1 Common in business to have over 1000 products that need forecasting at least monthly. 2 Forecasts are often required](https://reader034.fdocuments.net/reader034/viewer/2022050200/5f5369dd00b84f3b9d06f3b6/html5/thumbnails/130.jpg)
For further information
robjhyndman.com
Slides and references for this talk.
Links to all papers and books.
Links to R packages.
A blog about forecasting research.
Automatic time series forecasting Forecasts about automatic forecasting 59