# Forecasting algorithms

A number of algorithms are used in forecasting.

## One-step ahead

Every model supports one-step ahead forecasts based on the corresponding forecast equation. One-step ahead forecasts are needed to compute model errors during the model estimation process.

One-step ahead forecasts are computed sequentially for each data point by using computed level and trend states for the current point, and seasonal states for the last seasonal period.

Forecast error is computed by subtracting forecast value (estimated at the previous point) from the observed value at the current point. Overall model error, which is used for estimating the model, is computed as an average value of absolute squared forecast errors. Smaller errors correspond to a better model fit. Accuracy measures displayed in Statistical details provide several model summaries of the one-step ahead forecast errors.

## k-step ahead

k-step ahead forecasts are used to make predictions for any number of future values following the observed time series data. They are based on the same forecast equations as the one-step ahead forecasts for the specified model.

The number of forecast values that are generated is 20% of the length of historical data series by default. You can specify an exact number of values to be forecast in the Forecast dialog box. Any missing values at the end of a particular series will also be forecast, but they will not count towards the specified number of forecast periods.

## Confidence bounds

Confidence bounds provide the level of uncertainty that is associated with each forecast value. The bounds typically become wider further into the future, because more distant forecasts are less reliable. Confidence bounds provide relevant insights into the future behavior of the observed time series.

Computation of confidence bounds is based on the overall variance of forecast errors that are estimated on the observed data and a factor that depends on the specified model and on the number of steps from the last observed point.