Foundations to Frontier
Tests
K. Time Series and Sensor Data › K1 Classical Time Series

Exponential smoothing

Exponential smoothing forecasts with weighted averages of past observations, with weights that shrink geometrically with age. Adding a smoothed trend gives Holt's method, damping that trend gives the damped-trend method, and adding smoothed seasonal indices gives Holt–Winters. This page implements all of them with parameters fitted by one-step squared error. It shows that simple smoothing is the optimal forecast for an ARIMA(0,1,1) process, and compares the methods on series with a wandering level, a trend and a season.

Level 0: Foundation

★☆☆☆☆ Introductory⏱ 5 minGeneral audience. No mathematics required.

Averaging that forgets slowly

To guess tomorrow’s sales you might average the past few days, but recent days matter more than old ones. Exponential smoothing gives the newest observation the biggest weight and each older one a little less, so the average follows changes without jumping at every wiggle. If sales are rising, we also smooth the rate of rise. If they follow a weekly or yearly pattern, we smooth that pattern too.

Time-series lab
SES with α = 0.5 on a trend of 0.2 per step: one-step RMSE 2.45, 20-step forecast RMSE 2.18 (noise sd 2). SES forecasts a flat line and lags a trend by about slope/α.
Why engineers care

Exponential smoothing was developed for inventory control in the US Navy in the 1950s and still forecasts demand for many retailers today.

📝 Quick check (Level 0)
0/3 answered
  1. 1. Exponential smoothing gives the most weight to…
  2. 2. Holt's method adds a smoothed…
  3. 3. Holt–Winters also smooths…

Level 1: Beginner

★★☆☆☆ Basic⏱ 20 minSecondary-school mathematics: arithmetic and elementary algebra.

By hand

  • Simple exponential smoothing (SES): ℓ_t = ℓ_(t−1) + α(y_t − ℓ_(t−1)), forecast ŷ_(t+h) = ℓ_t. The weights α(1−α)^k decay geometrically with age.
  • Holt’s linear trend: a level ℓ and a slope b, each updated from the one-step error; forecast ℓ + hb.
  • Damped trend: forecast ℓ + (φ + φ² + … + φ^h)b, which levels off at ℓ + bφ/(1−φ). It is often the most reliable choice in practice.
  • Holt–Winters: adds seasonal indices s_t, either additive (y = ℓ + s) or multiplicative (y = ℓ × s).
  • Fitting: choose α, β, γ (and φ) to minimise the sum of squared one-step errors, or maximise the likelihood of the equivalent state-space model (ETS).
  • ETS taxonomy: Error (A/M), Trend (N/A/Ad) and Seasonal (N/A/M) give a family of models with exact likelihoods and prediction intervals.
📝 Quick check (Level 1)
0/3 answered
  1. 1. The SES forecast for every horizon is…
  2. 2. A damped trend forecast eventually…
  3. 3. ETS stands for…

Level 2: Intermediate

★★★☆☆ Intermediate⏱ 25 minUndergraduate students and practising engineers.

SES, Holt and damping

Exercise 1.

  • 3000 points of an ARIMA(0,1,1) with θ = −0.6: find the SSE-optimal α on a grid from 0.05 to 0.95.
  • A straight line with slope 0.5 plus noise: SES with α = 0.5 against Holt.
  • A damped-trend forecast with φ = 0.8 from level 10 and slope 1, 50 steps ahead.

Practice.

  • Fit parameters on one-step errors but evaluate on multi-step holdout forecasts.
  • Prefer the damped trend to a straight-line trend for long horizons.
  • Use multiplicative seasonality, or logs, when seasonal swings grow with the level.
  • Let automatic ETS selection by AICc choose among model forms for many series.
  • Tools: statsmodels ExponentialSmoothing and ETSModel, R forecast ets, StatsForecast AutoETS.
import numpy as np

def ses(y, alpha):
    level, errors = y[0], []
    for v in y[1:]:
        e = v - level
        errors.append(e)
        level = level + alpha * e
    return np.array(errors), level
🐍 Exercise 1: what smoothing parameters mean
Show that the best SES parameter for ARIMA(0,1,1) data is 1 + θ, measure how SES lags behind a trend while Holt follows it, and find where a damped trend levels off.
📝 Quick check (Level 2)
0/3 answered
  1. 1. For long horizons a good default is…
  2. 2. Seasonal swings growing with the level call for…
  3. 3. Automatic exponential smoothing in Python:

Level 3: Advanced

★★★★☆ Advanced⏱ 25 minGraduate level, with full derivations and proofs.

Theory

Equivalence with ARIMA. The SES one-step error is e_t = y_t − ℓ_(t−1). Rearranging the update gives y_t − y_(t−1) = e_t − (1−α)e_(t−1), an ARIMA(0,1,1) with θ = α − 1. So SES is the optimal forecast when the data follow that model. In Exercise 1, data with θ = −0.6 gave an SSE-optimal α of 0.4 = 1 + θ. Holt’s linear method corresponds to an ARIMA(0,2,2), and additive Holt–Winters to a seasonal ARIMA.

Lag behind a trend. On a straight line of slope b, the SES level must rise by b each step, so αe = b and the steady one-step error is b/α. In Exercise 1 it was 1.00 for b = 0.5 and α = 0.5. Holt adds a trend term and estimated the slope as 0.555. Smaller α smooths more noise but lags more.

Damping. The damped forecast adds φ + φ² + … + φ^h slopes, which converges to φ/(1−φ). With φ = 0.8 and b = 1 the forecast levels off 4 units above the level (14.00 from 10). Damping protects against extrapolating a trend that does not last.

📝 Quick check (Level 3)
0/3 answered
  1. 1. SES is optimal for…
  2. 2. On a straight line, SES lags by…
  3. 3. A damped trend with φ = 0.8 adds at most…

Level 4: Expert

★★★★★ Expert⏱ 30 minResearchers: original papers and open problems.

On series with a wandering level, a wandering trend, or a trend plus an evolving season, which smoothing method forecasts best one step and twelve steps ahead?

History.

  • R. Brown (1956) developed exponential smoothing for US Navy inventory control.
  • C. Holt (1957) added a trend, and P. Winters (1960) a season.
  • J. Muth (1960) showed that SES is optimal for a random walk observed with noise.
  • E. Gardner and E. McKenzie (1985) introduced the damped trend; R. Hyndman et al. (2002) put the methods into the ETS state-space framework with likelihoods and AIC selection.

Exercise 2.

  • 60 series of each kind, 120 points for fitting and 12 for testing:
    • level: a random walk with sd 0.5 plus noise with sd 1;
    • trend: a local linear trend whose slope wanders around 0.3;
    • seasonal: a trend of 0.2 per step plus a 12-step seasonal pattern of amplitude 5 that slowly evolves, plus noise.
  • Parameters are fitted by one-step squared error on grids. The damped Holt method also chooses φ from 0.8, 0.9 and 0.98.

Seed 0, RMSE at horizons 1 and 12:

series naive SES Holt damped Holt Holt–Winters
level 1.5, 2.2 1.2, 2.1 1.3, 3.2 1.2, 2.2 1.3, 2.4
trend 1.5, 4.8 1.3, 5.0 1.2, 2.3 1.2, 3.1 1.2, 1.9
seasonal 3.0, 2.7 3.1, 2.7 2.7, 11 2.6, 3.5 1.1, 1.3
  • Level series: SES was best one step ahead. Holt’s undamped trend extrapolated noise and was worst at 12 steps (3.2); damping fixed most of that (2.2).
  • Trend series: methods with a trend halved the 12-step error (Holt 2.3, Holt–Winters 1.9, against 4.8–5.0). Holt–Winters even beat Holt here, probably because its smaller grid of trend-smoothing values estimates the slope less noisily.
  • Seasonal series: only Holt–Winters modelled the season (1.1 and 1.3). Holt mistook the seasonal swing at the end of the data for a trend and was off by 11 after 12 steps.
  • Seeds 1 and 2: on seasonal series Holt–Winters gave 1.4/1.1 and 1.3/1.2 and Holt 11 and 10 at 12 steps. On trend series the 12-step errors were Holt 2.8 and 2.3, Holt–Winters 2.2 and 2.1, and naive 4.5 and 4.7.
🐍 Exercise 2 (research): on series with a wandering level, a wandering trend, or a trend plus an evolving season, which smoothing method forecasts best one step and twelve steps ahead?
Fit SES, Holt, damped Holt and Holt–Winters by one-step squared error on series with a wandering level, a trend and a season, and compare their 1- and 12-step forecasts with the naive method.

Exponential smoothing in practice

  • Retail and supply chain: ETS models forecast demand for millions of items; they are fast and robust.
  • Competitions: in M3 and M4, damped-trend ETS and combinations with ARIMA were hard to beat; Theta, a related method, won M3.
  • Prediction intervals come from the state-space form (ETS), not from the point-forecast recursions alone.
  • Hybrids: ES-RNN, which combines Holt–Winters with an LSTM, won M4.

References

  1. R. G. Brown (1959). Statistical Forecasting for Inventory Control. McGraw-Hill.
  2. C. C. Holt (1957/2004). “Forecasting seasonals and trends by exponentially weighted moving averages.” International Journal of Forecasting (reprint).
  3. P. R. Winters (1960). “Forecasting sales by exponentially weighted moving averages.” Management Science.
  4. E. S. Gardner and E. McKenzie (1985). “Forecasting trends in time series.” Management Science.
  5. R. J. Hyndman, A. B. Koehler, R. D. Snyder and S. Grose (2002). “A state space framework for automatic forecasting using exponential smoothing methods.” International Journal of Forecasting.