Measurements of Classi cation Performance:
Sensitivity and Speci city
1. Introduction
In medical decision-making and diagnostic testing, it’s essential to measure how accurately a test
or algorithm identi es a disease.
These measurements are called classi cation performance metrics, and the most important ones
are:
• Sensitivity (True Positive Rate)
• Speci city (True Negative Rate)
They are used to evaluate how well a diagnostic test or predictive model performs.
2. Basic Terminology
Before calculating sensitivity and speci city, we must understand the four possible outcomes of a
diagnostic test or classi cation system:
Actual
Test Result Positive Test Result Negative
Condition
Disease Present ✅ True Positive (TP) ❌ False Negative
(FN)
❌ False Positive
Disease Absent ✅ True Negative (TN)
(FP)
Explanation:
• True Positive (TP):
Test correctly identi es a diseased person as positive.
Example: A COVID test correctly says a sick person has COVID.
• False Positive (FP):
Test wrongly says a healthy person has the disease.
Example: A healthy person tests positive for COVID.
• True Negative (TN):
Test correctly identi es a healthy person as negative.
• False Negative (FN):
Test fails to identify a diseased person.
Example: A sick person tests negative due to test error.
fi
fi
fi
fi
fi
fi
fi
fi
fi
3. Confusion Matrix (Diagnostic Table)
Predicted: Predicted:
Positive Negative
Actual: Positive TP FN
Actual:
FP TN
Negative
This table helps calculate all performance metrics.
4. Sensitivity (True Positive Rate)
De nition:
Sensitivity measures the ability of a test to correctly identify patients who actually have the
disease.
It tells us how good the test is at detecting the disease.
Formula:
Sensitivity=TP+FNTP
Interpretation:
• High sensitivity → few missed cases (few false negatives).
• A sensitive test is useful for screening diseases (to catch as many real patients as possible).
Example:
If a COVID test correctly identi es 90 out of 100 actual COVID patients,
and 10 are missed, then:
Sensitivity=90+1090 =0.9=90%
➡ The test detects 90% of all true cases.
Clinical Signi cance:
• High sensitivity = good for ruling out a disease.
• Common rule:
“SnNout” — A Sensitive test, when Negative, rules OUT the disease.
fi
fi
fi
5. Speci city (True Negative Rate)
De nition:
Speci city measures the ability of a test to correctly identify people who do not have the
disease.
It shows how good the test is at identifying healthy individuals.
Formula:
Speci city=TN+FPTN
Interpretation:
• High speci city → few false positives (fewer healthy people labeled sick).
• A speci c test is useful for con rming a disease after screening.
Example:
If a test correctly identi es 85 out of 100 healthy individuals as negative,
and 15 are wrongly labeled positive, then:
Speci city=85+1585 =0.85=85%
➡ The test correctly identi es 85% of healthy people.
Clinical Signi cance:
• High speci city = good for ruling in a disease.
• Common rule:
“SpPin” — A Speci c test, when Positive, rules IN the disease.
6. Related Metrics (for complete understanding)
Metric Formula Meaning
(TP + TN) / (TP + TN +
Accuracy Overall correctness
FP + FN)
Precision (Positive How many predicted positives are
TP / (TP + FP)
Predictive Value) actually correct
Negative Predictive Value How many predicted negatives are
TN / (TN + FN)
(NPV) truly healthy
fi
fi
fi
fi
fi
fi
fi
fi
fi
fi
fi
fi
fi
7. Example Problem (Step-by-Step Calculation)
Scenario:
A diagnostic test is performed on 200 people.
• 100 have the disease
• 100 do not have the disease
Test results:
• True Positives (TP): 90
• False Negatives (FN): 10
• True Negatives (TN): 85
• False Positives (FP): 15
Calculations:
Sensitivity:
=TP+FNTP =90+1090 =0.9=90%
Speci city:
=TN+FPTN =85+1585 =0.85=85%
Accuracy:
=TP+TN+FP+FNTP+TN =20090+85 =0.875=87.5%
✅ The test correctly diagnoses 87.5% of all patients.
It is highly sensitive (detects most cases) and reasonably speci c (few false alarms).
8. Graphical Understanding (Simpli ed)
Actual Disease Status
------------------------------
Disease Present | TP | FN
Disease Absent | FP | TN
• Sensitivity → Focus on the “Disease Present” row
• Speci city → Focus on the “Disease Absent” row
fi
fi
fi
fi
9. Importance in Medical Informatics
In healthcare algorithms, sensitivity and speci city are used to:
• Evaluate diagnostic tools (e.g., cancer or diabetes tests)
• Measure AI/ML model accuracy in disease detection
• Balance false positives and false negatives for patient safety
fi