Macro Recall#
The unweighted mean of per-class recall values.
Important
✨ AI-generated content. This page was written with the assistance of an AI language model and is provided as a learning aid. Despite careful review, it may still contain mistakes, omissions, or out-of-date information. Whether you are new to the topic, a team lead, or a senior practitioner, treat it as a starting point rather than an authoritative reference: read it critically and independently verify anything you act on (code, commands, figures, and factual claims) against official documentation and primary sources before relying on it.
What it is#
Recall is the share of actual positives the model catches, \(\text{Recall} = TP/(TP+FN)\). For \(K\) classes, compute recall per class (one-vs-rest) and take the unweighted mean:
Every class counts equally regardless of how many samples it has.
A useful equivalence#
In single-label classification, macro recall is exactly balanced accuracy — the average per-class hit rate. That makes it a go-to headline metric for imbalanced problems, because it refuses to let a dominant class inflate the score.
Macro vs micro vs weighted#
Macro — equal weight per class; good when every class is equally important.
Micro — global TP and FN pooled first; dominated by large classes.
Weighted — per-class recall averaged by the number of true samples in each class.
Worked example#
Three classes with Recall(A)=0.90, Recall(B)=0.60, Recall(C)=0.30:
Even though C is rare, it carries the same weight as A.
Pitfalls and edge cases#
Ignores false positives — recall says nothing about precision, so a model that over-predicts a class can still score well; pair it with macro precision or macro F1.
Empty classes — a class with no true samples has undefined recall and must be handled before averaging.
In code#
from sklearn.metrics import recall_score, balanced_accuracy_score
macro = recall_score(y_true, y_pred, average="macro")
# in single-label problems this equals:
bal_acc = balanced_accuracy_score(y_true, y_pred)
Theme: Classification & Averaging Metrics · All terminology
Hint
Mind map — connected ideas
Macro Precision · Macro F1 · Micro Recall · Macro AUROC (Macro-Averaged AUROC)
Hint
More in Classification & Averaging Metrics
Accuracy · AUC (Area Under the Curve) · Average Precision (AP) · Binary Classification · Classification Probability · Discriminatory Power · F1-score · Gini Coefficient · Harmonic Mean · Log Loss (also called Logarithmic Loss or Cross-Entropy Loss) · Macro AUC · Macro AUROC (Macro-Averaged AUROC) · Macro Averaging · Macro F1
See also
Source article Adapted (context, re-expressed) in our own words from: Macro Recall (insightful-data-lab.com).