Calculating WAPE

WAPE stands for weighted absolute percentage error. It is a very simple calculation that is woefully under-represented on the internets…so here goes the most simple explanation.

1) You have a set of baseline measurements that are, in your professional opinion, the best (often actuals)
2) You have a set of experiment values for which you want to calculate the WAPE against the baseline.
3) For each value in baseline, calculate an absolute difference field (e.g., absolute value of Baseline – Experiment)
4) Sum all of the absolute differences
5) Divide that sum of absolute differences by the sum of all baseline values.

Boom. You have WAPE. The benefit for WAPE is that it lets you see your error on an item by item basis at an aggregate level. Replay. If you just calculated the error at an aggregate level, a lot of item level shifts (aka-errors) would cancel themselves out…and that is bad. If you just averaged the errors on the item level, you might have a nominal item with a high error rate seriously throwing off your results. WAPE is the way to get the aggregate error of your set of measurements.

Simple Example: What does a fruit shopper purchase at a farmer’s market?
Baseline: what we measured this weekend:
100 Apples
20 Pears
10 Bananas
Experiment: what we predicted they would buy
80 Apples
30 Pears
5 Bananas

The worst thing you can do is just say “expected purchases v. actual purchases.” With this, you would have 115 experiment v 130 actual, or 15/130 = 11.5% error. The problem is that some of your under-estimates cancel out some of your over-estimates.

Absolute Difference

Absolute Error

If we were to average these values, we would end up with .4 or 40% error rate (or MAPE). . But this is not right…our biggest measurement was most accurate, so we should punish ourselves less than the average. This is where WAPE comes in: weighting your errors based on their significance.


Here, our WAPE is 27%, Not as good as delta/actuals (11.5%), not as bad as MAPE (40%), but just right at a weight adjusted 27%.

Let me know if you have any questions.




Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s