MAE Calculator
Mean absolute error between actual and predicted values.
About this tool
Enter the actual values and the predicted values and get the mean absolute error: the average size of the errors, in the same units as your data, ignoring direction. Lower is better and 0 is perfect.
How to use
How it works
MAE = (1/n) Σ |yᵢ − ŷᵢ|. Every error counts in proportion to its size, so it is less affected by outliers than MSE or RMSE and easy to explain: on average the prediction is off by this much.
MAE = (1/n) · Σ |yᵢ − ŷᵢ|
Worked example
Four predictions
- Input
- Actual: 3, 5, 2.5, 7 Predicted: 2.5, 5, 4, 8
- Output
- MAE 0.75 (n = 4)
- Walkthrough
- The absolute errors are 0.5, 0, 1.5 and 1, which sum to 3. 3 / 4 = 0.75.
Limitations
- The two lists must have the same length.
- Not scale-free: compare MAE only across models on the same target.
- Treats over- and under-prediction alike.
Questions
How do I calculate mean absolute error?
MAE or RMSE?
What is a good MAE?
Can MAE be negative?
Features
- Same units as data
- Runs in your browser
- Equal-length check
Related resources
Guides and videos from around the web—opens on YouTube or the publisher’s site.
Mean, Variance and Standard Deviation
StatQuest with Josh Starmer
Stats foundations behind many ML metrics tools.
Watch on YouTubeTensorFlow 2.0 Complete Course
freeCodeCamp.org
Practical ML stack context next to AI utilities.
Watch on YouTube
- DeepLearning.AI
DeepLearning.AI
Courses and explainers for modern AI tooling.
- Metrics and scoring
scikit-learn
Precision, recall, F1 definitions used by AI metric tools.