Absolute error

Absolute error is defined as the absolute value of the difference between the forecast value and actual value. Let's imagine a scenario as follows:

Actual value

Predicted value

Error

Absolute error

Data point 1

100

120

20

20

Data point 2

100

80

-20

20

Overall

200

200

0

40

In the preceding scenario, we see that the overall error is 0 (as one error is +20 and the other is -20). If we assume that the overall error of the model is 0, we are missing out the fact that the model is not working well on individual data points.

Hence, in order to avoid the issue of a positive error and negative error canceling each other out and thus resulting in minimal error, we consider the absolute ...

Get Hands-On Machine Learning on Google Cloud Platform now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.