Calculate average error (mean absolute error) from a list of errors or measured vs true values, with mean error, MSE, RMSE, MAPE and percent error.

One per line, or separated by spaces, semicolons or a comma and space. Negative errors are allowed.

Optional settings


Related Calculators

Calculator Functions

FunctionWhat it doesWhat it requires
Average error from error valuesFinds the mean absolute error of a list of errors, along with the mean error, MSE and RMSERequires one or more error values, which can be positive or negative
Average error from measured and true valuesFinds each error as measured minus true, then the mean absolute error, mean error, MSE, RMSE and MAPERequires a list of measured or predicted values and a list of true values, with the same count and order
Percent error of one measurementFinds how far one measured value sits from the true value, as a percentageRequires a measured value and a true or accepted value that is not zero

Each list holds up to 10,000 numbers, entered one per line or separated by spaces, semicolons or a comma and a space. The headline result of the two list functions is the average error, which is the mean absolute error (MAE).

Average Error Formulas

MAE = (|eโ‚| + โ€ฆ + |eโ‚™|) รท n [1]
MAEAverage error, also called mean absolute error, in the same unit as the data
eOne error: a measured or predicted value minus the true value
nNumber of errors

Taking the absolute value of each error first stops positive and negative errors from canceling, so MAE is the typical size of an error regardless of direction.

Average error from error values

The main formula applies directly to the list. For the errors 3, โˆ’2, 4 and โˆ’1, the absolute values add to 10, so MAE = 10 รท 4 = 2.5.

ME = (eโ‚ + โ€ฆ + eโ‚™) รท n

Mean error (ME) keeps the signs, so it shows bias: a positive value means results run high, and a negative value means they run low. The same four errors give ME = 4 รท 4 = 1.

RMSE =
โˆš((eโ‚ยฒ + โ€ฆ + eโ‚™ยฒ) รท n) [1]

The value inside the square root is the mean squared error (MSE). The four errors give MSE = 30 รท 4 = 7.5 and RMSE = 2.7386.

Average error from measured and true values

e = measured โˆ’ true

Each pair is turned into an error, and the formulas above are applied to those errors. Measured values of 10, 12 and 9 against true values of 11, 10 and 9 give errors of โˆ’1, 2 and 0, so MAE = 3 รท 3 = 1.

MAPE = mean of
|e รท true| ร— 100 [1]

Mean absolute percent error (MAPE) expresses each error as a share of its true value before averaging. The same three pairs give (0.0909 + 0.2 + 0) รท 3 ร— 100 = 9.697%. MAPE is not reported when any true value is 0, because that term would divide by zero [1].

Forecasting texts usually define an error as the actual value minus the forecast [1], the reverse of the order used here. That flips the sign of the mean error and leaves MAE, MSE, RMSE and MAPE unchanged.

Percent error of one measurement

PE = (measured โˆ’ true) รท
true ร— 100

A reading of 9.6 against a true value of 10 gives (9.6 โˆ’ 10) รท 10 ร— 100 = โˆ’4%, which is 4% below the true value. The result also shows the absolute percent error, the error and the absolute error.

Limits of This Estimate

  • Percent error and MAPE are undefined when a true value is zero and become extreme when a true value is close to zero [1].
  • A mean error near zero does not mean the errors are small. Large positive and negative errors can cancel, which is why MAE and RMSE are reported beside it.
  • The agreement labels on a percent error result (under 1%, under 5%, 5% to 10% and over 10%) are descriptive bands used by this calculator, not a published standard.

Sources

  1. Hyndman and Athanasopoulos, Forecasting: Principles and Practice (3rd ed.), Section 5.8: definitions of MAE, RMSE, percentage error and MAPE, and the zero-value limit of percentage errors