# Holt-Winters

Learn how to use Holt-Winters exponential smoothing for forecasting.

## We'll cover the following

## Understanding Holt-Winters

Past data is compressed using **exponential smoothing** via the **Holt-Winters method** to anticipate typical values for the present and the future. Exponential smoothing means smoothing a time series using an **exponentially weighted moving average (EWMA)**. Like a rolling mean, it can be used on past data to make it smoother but also to make forecasts for future values.

An exponentially weighted moving average

The Holt-Winters method includes both a slope smoothing component to take the trend into account and a seasonal smoothing. So the model gets three equations—one for the level, one for the trend, and one for seasonality. Furthermore, each of these three equations has two versions—**additive** and **multiplicative**.

**Level****Additive**:$\ell_t = \alpha (y_t-s_{t-m}) + (1-\alpha) (\ell_{t-1} +b_{t-1})$ **Multiplicative**:$\ell_{t} = \alpha \frac{y_{t}}{s_{t-m}} + (1 - \alpha)(\ell_{t-1} + b_{t-1})$

**Trend****Additive**:$b_t = \beta (\ell_t-\ell_{t-1})+(1-\beta )b_{t-1}$ **Multiplicative**:$b_{t} = \beta(\ell_{t}-\ell_{t-1}) + (1 - \beta)b_{t-1}$

**Seasonality****Additive**:$s_t=\gamma(y_t-\ell_{t-1}-b_{t-1})+(1-\gamma)s_{t-m}$ **Multiplicative:**$s_{t} = \gamma \frac{y_{t}}{(\ell_{t-1} + b_{t-1})} + (1 - \gamma)s_{t-m}$

Where

## Forecasting with Holt-Winters

In Python, Holt-Winters models are available in the `statsmodels`

package.

Get hands-on with 1400+ tech skills courses.