Library · Metric

sMAPE: symmetric mean absolute percentage error

sMAPE was designed to fix the unbounded errors of MAPE. It is bounded, but it penalises a forecast that is too low more than one that is too high by the same amount, and every period with zero demand gets the maximum error.

By , published

Definition

The symmetric mean absolute percentage error divides each absolute error by the average of the actual value and the forecast. It was used as the main measure of the M3 competition.

sMAPE = mean( 2 |yt − ft| ÷ ( |yt| + |ft| ) ) × 100

The value lies between 0 and 200. The name suggests that over-forecasts and under-forecasts are treated alike. Goodwin and Lawton showed in 1999 that they are not.

Worked example

import numpy as np

def smape(y, f):
    y, f = np.asarray(y, float), np.asarray(f, float)
    return 100 * np.mean(2 * np.abs(y - f) / (np.abs(y) + np.abs(f)))

print(f"actual 100, forecast 150 (50 too high): {smape([100], [150]):.1f}")
print(f"actual 100, forecast  50 (50 too low):  {smape([100], [50]):.1f}")

demand = [0, 0, 5, 0]
print(f"zero demand, forecast 0.1 everywhere:    {smape(demand, [0.1] * 4):.1f}")
print(f"zero demand, forecast 1.25 everywhere:   {smape(demand, [1.25] * 4):.1f}")

Output, produced by running the code above when this page was built:

actual 100, forecast 150 (50 too high): 40.0
actual 100, forecast  50 (50 too low):  66.7
zero demand, forecast 0.1 everywhere:    198.0
zero demand, forecast 1.25 everywhere:   180.0

The same error of 50 units costs more when the forecast is too low. On the series with zeros, three of the four periods reach the maximum of 200 whatever the forecast, so the score barely separates a careless forecast from a sensible one.

Where it misleads

When the actual value is zero and the forecast is not, the term equals 200 regardless of how far the forecast is from zero. When both are zero the term is 0 divided by 0, and software packages disagree on what to do with it: some return 0, some skip the period, some return an error. Two reports of an sMAPE on intermittent data are therefore not comparable unless the convention is stated.

Because of the asymmetry, selecting a model on sMAPE pushes forecasts upward. For series far from zero, the effect is small. For low volumes it changes which method wins. Scaled errors such as MASE were proposed for this reason, and WAPE is the usual choice when a percentage is required by the business.

In our work

We do not use sMAPE to choose a model. When a client reports it historically, we recompute it with their convention so that the series stays comparable, and add a scaled error and the bias next to it.

References

  1. Goodwin, P., Lawton, R. (1999). On the asymmetry of the symmetric MAPE. International Journal of Forecasting, 15(4), 405-408. doi:10.1016/S0169-2070(99)00007-2
  2. Makridakis, S. (1993). Accuracy measures: theoretical and practical concerns. International Journal of Forecasting, 9(4), 527-529. doi:10.1016/0169-2070(93)90079-3
  3. Hyndman, R. J., Koehler, A. B. (2006). Another look at measures of forecast accuracy. International Journal of Forecasting, 22(4), 679-688. doi:10.1016/j.ijforecast.2006.03.001

Have a question like this one on your own data? Tell us what you need in a few lines.

Send us the brief

Related pages

  • MAPE: mean absolute percentage errorMAPE is easy to explain and is the measure most planning teams already report. It is undefined when the actual value is zero, it explodes on low volumes, and the forecast that minimises it sits below the mean.
  • WAPE: weighted absolute percentage errorWAPE, also called the MAD/mean ratio, is the total absolute error divided by the total demand. It stays defined when some periods are zero and is the percentage measure that survives a catalogue of slow items.
  • MASE: mean absolute scaled errorMASE compares the absolute error of a forecast with the error a naive forecast made on the history. Below 1, the forecast beats that naive benchmark. On series that are mostly zeros, a forecast of zero gets the best score.
All library pages