Weighted Moving Averages

Lesson3 min readQuantitative Forecasting

A weighted moving average (WMA) forecasts the next period as a weighted average of the last n actual values, with larger weights on more recent periods. It keeps the simplicity of a simple moving average but reacts faster to change, because last month matters more than three months ago.

The formula

Forecast(t+1) = w1×Dt + w2×Dt-1 + … + wn×Dt-n+1, with w1 + w2 + … + wn = 1

The weights must add up to 1 (or you divide by their sum). Giving the heaviest weight to the latest period is the usual choice, but it is a judgment you can test.

Worked example: ABC Clothing, again

Use the same monthly sales as the moving-average lesson (Jan 100 … Dec 125) with weights 0.5 for the last month, 0.3 for the month before and 0.2 for the one before that.

Forecast for Jan = 0.5×125 + 0.3×120 + 0.2×135 = 62.5 + 36 + 27 = 125.5 units

Compare both methods on the nine months that have a forecast (April to December):

Method Sum of absolute errors MAD (mean absolute deviation) Forecast for January
3-month simple MA 150.0 16.7 126.7
3-month weighted MA (0.5/0.3/0.2) 128.0 14.2 125.5

The weighted version tracks the rise and fall slightly better, cutting the average error by about 15 percent on this data. It still lags a trend, because it is still an average of the past, only a more responsive one.

How to choose the weights

  • Start with weights that fall steadily with age, for example 0.5, 0.3, 0.2.
  • Try a few sets on your history and compare MAD or MAPE on periods the weights were not tuned on.
  • More weight on recent data means faster reaction and more noise. Flatter weights mean smoother and slower.

Strengths and limits

  • Strengths: easy to explain, easy to build in a spreadsheet, more responsive than the simple average.
  • Limits: still lags trends, ignores seasonality, needs n periods of history per item, and you must choose the weights yourself.
  • If you want weights that decline smoothly and automatically with one parameter, look at exponential smoothing, and for trend look at Holt’s model.

Common mistakes

  • Weights that do not add to 1, which biases every forecast.
  • Choosing weights by gut feel and never testing them.
  • Using it on strongly seasonal items.

Key takeaways

  • WMA = weighted average of the last n values, with weights summing to 1.
  • Recent periods get more weight, so it reacts faster than a simple average.
  • Test weights on history, and measure the forecast error.
  • For trend or seasonality, move to Holt’s or Holt-Winters methods.

Put it into practice

Ready-made tools that apply this topic:

Browse all templates and bundles →

Frequently asked questions

What is a weighted moving average?

A weighted moving average forecasts the next period as a weighted average of the last n actual values, giving more weight to recent periods, with weights that add up to 1.

How do you calculate a weighted moving average?

Multiply each of the last n values by its weight and add the results. With weights 0.5, 0.3 and 0.2 on values 125, 120 and 135 the forecast is 0.5×125 + 0.3×120 + 0.2×135 = 125.5.

What is the difference between a simple and a weighted moving average?

A simple moving average gives every period equal weight. A weighted one gives larger weights to recent periods, so it responds faster to changes in demand.

How do I choose weights for a weighted moving average?

Start with weights that decline with age, test several sets against historical data and choose the set with the lowest forecast error on data not used to tune it.

When should I not use a weighted moving average?

Avoid it for data with a clear trend or seasonality, because it still lags behind and does not model seasonal patterns. Use Holt or Holt-Winters methods instead.