generate 1-step forecasts for a time series using an exponential smoothing model
OneStepForecasts(model, extraparameters, opts)
OneStepForecasts(model, ts, extraparameters, opts)
Exponential smoothing model
Time series consisting of a single data set
(optional) table of parameter values
(optional) equation(s) of the form optionname = value, where optionname is either output or runs
The OneStepForecasts command generates a single step forecast for every data point in ts, using the exponential smoothing model model.
If a TimeSeries ts is not given, then the time series that model is created from will be used.
Single step forecasts are generated during simulation as the point forecast for the next value of the time series. By comparing this with the actual, realized value, the error εt is determined. Conversely, the one step forecast can be obtained from the actual time series by either subtracting εt (for a model with additive errors) or by dividing by 1+εt (for multiplicative errors).
The value of any of the parameters can be overridden by supplying the extraparameters option. It is a table in the format returned by Initialize: its indices are global names corresponding to parameters, and the values are their values as explained in the Exponential smoothing model help page.
output: point, runs, percentiles(p1, p2, ..., pn), quantiles(q1, q2, ..., qn), or confidenceintervals(c1, c2, ..., cn)
By default, Maple will generate the one step forecast by assuming the error is 0. Other forms of output can be selected using the output option. This affects the error values used to generate the values in the one step forecast time series, but since the forecasts are still single step, these errors are not propagated to future values.
output = percentiles(p1, p2, ..., pn) returns n time series that represent the p1th, p2th, ..., pnth percentile of the distribution of the values generated by the model. This is obtained via simulation.
output = quantiles(q1, q2, ..., qn) returns n time series that represent the q1th, q2th, ..., qnth quantile of the distribution of the values generated by the model. The only difference with percentiles is that, for example, p1 = 5 will be interpreted in the same way as q1 = 0.05.
output = confidenceintervals(c1, c2, ..., cn) returns 2⁢n+1 time series: the 50 - ci/2 and 50 + ci/2 percentiles for i from 1 to n, and the 50th percentile. For example, confidenceintervals(80, 95) will return the 2.5, 10, 50, 90, and 97.5 percentiles.
output = runs returns all simulated future time series. This requires that the runs = k option is also included. (See below.) This is not particularly useful for one step forecasts: because errors are not propagated forward in time, there is no particular relationship between subsequent data points in one run. This option is allowed mainly for compatibility with the Forecast command.
output = point selects the default behavior of point forecasts obtained by setting all future residuals to 0.
runs: nonnegative integer
For any setting of the output option other than point, Maple will run multiple one step forecasts. The runs option determines the number of forecasting runs used to arrive at this output. If output is of the form percentiles(p1, p2, ..., pn) or quantiles(q1, q2, ..., qn) or confidenceintervals(c1, c2, ..., cn), then by default, Maple chooses the number of runs between 50 and 2000 depending on the particular values chosen. For example, for percentiles(10, 50, 70), the default number of runs is 225. The runs option overrides this default. It is a required option if output = runs is selected: there is no default value. If output = point, then the runs option is ignored.
Consider the following time series. It represents international tourist visitor nights in Australia.
ts≔Time seriesVisitor nights24 rows of data:2005-Jan-01 - 2010-Oct-01
First, an exponential smoothing model can be fit to the data:
One step point forecasts of this model can be found from the above model:
pfc≔Time seriesVisitor nights (1 step forecasts)24 rows of data:2005-Jan-01 - 2010-Oct-01
The time series can also be specified explicitly:
pfc2≔Time seriesVisitor nights (1 step forecasts)24 rows of data:2005-Jan-01 - 2010-Oct-01
Confidence intervals can be added to the output:
cis≔Time seriesVisitor nights (1 step forecast - 2 percentile), ..., Visitor nights (1 step forecast - 98 percentile)24 rows of data:2005-Jan-01 - 2010-Oct-01
If we use a larger number of runs, the confidence intervals will be slightly more accurate:
cis2≔Time seriesVisitor nights (1 step forecast - 2 percentile), ..., Visitor nights (1 step forecast - 98 percentile)24 rows of data:2005-Jan-01 - 2010-Oct-01
Hyndman, R.J. and Athanasopoulos, G. (2013) Forecasting: principles and practice. http://otexts.org/fpp/. Accessed on 2013-10-09.
Hyndman, R.J., Koehler, A.B., Ord, J.K., and Snyder, R.D. (2008) Forecasting with Exponential Smoothing: The State Space Approach. Springer Series in Statistics. Springer-Verlag Berlin Heidelberg.
The TimeSeriesAnalysis[OneStepForecasts] command was introduced in Maple 18.
For more information on Maple 18 changes, see Updates in Maple 18.
The TimeSeriesAnalysis[OneStepForecasts] command was updated in Maple 2015.
Download Help Document
What kind of issue would you like to report? (Optional)