Labeled SetGet the app
Menu

Concept · filed under Machine learning basics (AI-900)

Precision vs recall, read off a confusion matrix

Precision is the share of a model’s positive calls that turned out right; recall is the share of real positives the model managed to find. Both come straight off a confusion matrix, which sorts every prediction into true positive, false positive, false negative or true negative. AI-900 tested this and AI-901 leaves it out. The same four cells still appear wherever a classifier gets evaluated.

  • ExamAI-901 (replaced AI-900 on June 30, 2026)
  • ScopeAI-900 only · not on AI-901
  • Questions here7
  • UpdatedOct 19, 2026

Fig. 1

PredictedActualCancelsStaysCancelsStays36True positive24False negative12False positive128True negativeAccuracy0.82(TP + TN) / allPrecision0.75TP / (TP + FP)Recall0.60TP / (TP + FN)
Fig. 1 A churn model checked against 200 customers whose outcome is now known.

Reading the four cells

A confusion matrix sets what the model predicted against what actually happened. In the figure the model flagged 48 customers as likely to cancel, and 36 of them did. That is precision: 36 out of 48, or 0.75. Sixty customers really canceled, and the model caught 36 of them. That is recall: 36 out of 60, or 0.60.

Accuracy counts every correct cell, 164 out of 200 or 0.82, and looks the healthiest of the three. It will whenever most customers stay: a model that predicted “stays” for everyone would score 0.70 here and catch nobody.

Nothing here needs a memorized formula. Both numbers put the true positives on top; they differ only in which mistake joins them underneath. Precision adds the false alarms, recall adds the misses.

Precision and recall apply to classification, one of the supervised model types set out in supervised vs unsupervised learning. Features, labels and training data are on the machine learning basics topic.

Table 1

Which number to watch

The same churn model under two retention plans
PlanThe costly mistakeWatch
Give every flagged customer a 30% discountDiscounts for people who were staying anyway (false positives)Precision
Send every flagged customer a short check-in emailMissing someone who then leaves (false negatives)Recall
Report one headline figure upwardA weak model hidden behind a common outcomeAccuracy, with the other two beside it

The model didn’t change between rows. The price of each kind of mistake did.

Other model types

Regression is judged by how far predictions land from the real values: mean absolute error (MAE), root mean squared error (RMSE) and the coefficient of determination (R²). Clustering is judged by how tight each group is and how far apart the groups sit. Precision and recall belong to classification.

Where this meets AI-901

Split the same matrix by customer group and you have a fairness check: a model whose recall is much lower for one group misses that group more often. Fairness is one of the six principles the AI-901 study guide does list; responsible AI principles covers how it is tested.

Worksheet

Four cells, two ratios

Some of these need arithmetic. Sketch the four cells before you divide.

Questions come in batches of five. Pick an answer for each, then evaluate the batch: notes on all four options open under every question.

Accuracy by batch

0 evaluated · 0 right · 7 to go

Batch 1 questions 1–5

  1. 01

    What is the purpose of the confusion matrix in Azure ML model evaluation?

    Your label —The notes on all four options open when this batch is evaluated.

  2. 02

    Which metric would be most appropriate for evaluating a binary classification model in Azure ML?

    Your label —The notes on all four options open when this batch is evaluated.

  3. 03

    What is the purpose of model evaluation in machine learning?

    Your label —The notes on all four options open when this batch is evaluated.

  4. 04

    A fraud model's results on a test set: 40 true positives, 10 false positives, 20 false negatives and 30 true negatives. What is its precision?

    Your label —The notes on all four options open when this batch is evaluated.

  5. 05

    A screening model flags patients for a follow-up test. Missing a patient who has the disease is far more costly than an extra test for a healthy one. Which metric should the team prioritize?

    Your label —The notes on all four options open when this batch is evaluated.

0 of 5 labeled

Batch 2 questions 6–7

  1. 06

    A defect-detection model is tested on 100 parts: 30 true positives, 5 false positives, 15 false negatives and 50 true negatives. What is its recall?

    Your label —The notes on all four options open when this batch is evaluated.

  2. 07

    A spam filter moves suspected spam to the junk folder. A real customer email lost in junk costs the business far more than some spam reaching the inbox. Which metric should the team prioritize?

    Your label —The notes on all four options open when this batch is evaluated.

0 of 2 labeled

Keep these

  • Precision: of the cases the model flagged, how many were real.
  • Recall: of the real cases, how many the model flagged.
  • Accuracy flatters a model when one outcome is rare.
  • Which to favor depends on what each kind of mistake costs.