← Industrial & Systems Engineering Studio
Moving average, smoothing & MAD/MAPE

Demand Forecasting Calculator

Forecast the next period from a demand time series using a simple moving average, a weighted moving average, or single exponential smoothing — and measure how well each method fits with MAD, MSE, MAPE, and forecast bias. Everything recomputes live in your browser.

Inputs
One-step-ahead forecast
55.33
units, next period
Accuracy (over 5 compared periods)
MAD (mean abs. deviation)4.933
MSE (mean squared error)30.489
MAPE (mean abs. % error)9.23%
Bias (mean error)4.933
A bias near zero means the method is neither consistently over- nor under-forecasting. Lower MAD/MSE/MAPE means a tighter fit.
Period-by-period
PeriodActualForecastError
142
245
343
45043.336.67
548462
655478
753512
858526
955.33
SMA: F = (A₁+…+Aₖ)/k  ·  WMA: F = Σ wᵢAᵢ / Σ wᵢ  ·  SES: Fₜ = α·Aₜ₋₁ + (1−α)·Fₜ₋₁  ·  MAD = Σ|e|/n  ·  MAPE = (Σ|e/A|/n)·100

About the Demand Forecasting Calculator

Demand forecasting estimates future demand from historical data so you can plan production, inventory, staffing, and capacity. This calculator implements three of the most widely taught time-series methods — the simple moving average, the weighted moving average, and single (simple) exponential smoothing — and reports the standard forecast-accuracy metrics MAD, MSE, MAPE, and bias so you can compare how well each method tracks your data. All computation runs live in your browser.

Simple and weighted moving averages

A simple moving average (SMA) forecasts the next period as the unweighted mean of the last k actual values: F = (Aₜ + Aₜ₋₁ + … + Aₜ₋ₖ₊₁) / k. Larger k smooths out noise but lags behind trends; smaller k responds faster but is jumpier. A weighted moving average (WMA) keeps the same window but assigns larger weights to more recent periods so the forecast reacts more quickly to recent change: F = Σ(wᵢ·Aᵢ) / Σwᵢ. Weights do not have to sum to one — this tool normalises them by their total — but they are conventionally listed most-recent-first.

Single exponential smoothing

Single exponential smoothing (SES) is a recursive average that weights every past observation, with weights that decay geometrically into the past: Fₜ = α·Aₜ₋₁ + (1−α)·Fₜ₋₁. The smoothing constant α (between 0 and 1) controls responsiveness — a high α (say 0.5–0.8) tracks recent change quickly but passes through more noise, while a low α (0.1–0.2) produces a very smooth, slow-moving forecast. SES needs a starting value; a common convention, used here, is to seed the first forecast with the first actual observation. SES is best for series that are roughly level with no strong trend or seasonality.

Forecast accuracy: MAD, MSE, MAPE, and bias

To compare methods you measure the forecast errors e = Actual − Forecast across the historical periods. MAD (mean absolute deviation) = Σ|e|/n is the average size of the error in the original units — easy to interpret. MSE (mean squared error) = Σe²/n squares the errors, so it penalises large misses more heavily. MAPE (mean absolute percentage error) = (Σ|e/Actual|/n)·100 expresses error as a percentage, which makes it comparable across products of different magnitudes (but it blows up when actuals are near zero). Bias, or mean error = Σe/n, reveals systematic over- or under-forecasting: a positive bias means you are under-forecasting on average, a negative bias means you are over-forecasting.

Choosing and tuning a method

There is no universally best method — pick the one with the lowest error metrics on your data, and watch the bias. If a method has low MAD but a large bias, it is consistently off in one direction and may need a trend component. For data with a clear trend, move beyond these methods to double exponential smoothing (Holt’s method); for seasonal data use Holt-Winters. To tune α in exponential smoothing, try several values and choose the one that minimises MSE or MAD over a holdout period. Remember that fitting accuracy on history is optimistic — always validate on data the model has not seen before trusting a forecast.

Frequently asked questions

How many periods of history do I need?

For a simple or weighted moving average you need at least as many periods as the window k. Exponential smoothing technically needs only one seed value, but in practice a dozen or more periods give far more reliable accuracy metrics. More history helps you detect trend and seasonality and makes the MAD/MSE/MAPE estimates more stable.

What is a good value for the smoothing constant α?

There is no fixed answer — it depends on how noisy and how fast-changing your demand is. A common starting range is 0.1 to 0.3 for stable demand and 0.3 to 0.5 when you want faster response. The rigorous approach is to try a range of α values and pick the one that minimises MSE (or MAD) over your data.

Should I use MAD, MSE, or MAPE?

Use MAD when you want an error in the same units as demand and treat all misses equally. Use MSE when large errors are disproportionately costly, since squaring penalises them more. Use MAPE when you need to compare accuracy across items of very different volume — but avoid it when actual demand is ever zero or near zero, because the percentage error explodes.

What does forecast bias tell me?

Bias (mean error) measures systematic direction of error. A bias near zero means over- and under-forecasts roughly cancel. A persistently positive bias means the method under-forecasts (actuals exceed forecasts), and a negative bias means it over-forecasts. A biased forecast usually signals a missing trend or seasonal component.

Why does the moving average lag behind a trend?

A moving average is centred on past data, so when demand is steadily rising or falling, the average of older, lower (or higher) values trails the current level. The longer the window, the larger the lag. To track trends, shorten the window, weight recent periods more heavily, or switch to a trend-aware method such as Holt’s double exponential smoothing.

Related tools & guides

Demand Forecasting GuideEOQ CalculatorEPQ / Production Order Quantity CalculatorLinear Regression & Correlation CalculatorIndustrial Engineering Exam Prep