2×2 Tables

Diagnostic test accuracy: sensitivity, specificity, PPV, NPV

Back

What is a 2×2 table?

A 2×2 table summarizes two binary variables. In diagnostics, one axis is the true condition (disease present/absent) and the other is the test result (positive/negative).

Condition + Condition −
Test + True Positive (TP) False Positive (FP)
Test − False Negative (FN) True Negative (TN)

Real Dental Scenario

AI Caries Detection vs Clinical Examination

Scenario: A dental clinic tested 200 patients for caries using a new AI detection tool. Results were compared against clinical examination (gold standard).

True Positives
72
False Positives
8
False Negatives
12
True Negatives
108

1 Building the 2×2 Table

Caries Present
(Gold Standard +)
Caries Absent
(Gold Standard −)
Total
AI Positive
AI Negative
Total

2 Sensitivity (True Positive Rate)

Sensitivity = TP / (TP + FN)

3 Specificity (True Negative Rate)

Specificity = TN / (TN + FP)

4 Positive Predictive Value (PPV)

PPV = TP / (TP + FP)

5 Negative Predictive Value (NPV)

NPV = TN / (TN + FN)

Clinical Summary: AI Caries Detection Performance

Sensitivity
85.7%
Specificity
93.1%
PPV
90.0%
NPV
90.0%

Recommendation: This AI tool shows strong diagnostic performance. However, with a sensitivity of 85.7%, approximately 1 in 7 caries cases may be missed. For screening purposes this is acceptable, but for definitive diagnosis, clinical examination should remain the primary method with AI as a supplementary tool.

Prevalence in sample = 84/200 = 42%. PPV/NPV will shift if prevalence changes in the population.

Interactive calculator

Enter TP/FP/FN/TN (e.g., caries detection test vs reference standard) and compute metrics.

Sensitivity
-
Specificity
-
PPV
-
NPV
-
Tip: PPV/NPV change with prevalence; sensitivity/specificity are more intrinsic to the test.

Metric definitions

  • Sensitivity = TP / (TP + FN) — among condition+, how often test is +
  • Specificity = TN / (TN + FP) — among condition−, how often test is −
  • PPV = TP / (TP + FP) — among test+, probability condition is present
  • NPV = TN / (TN + FN) — among test−, probability condition is absent

Visual: sensitivity & specificity

Dental example (quick interpretation)

For a caries detection device, high sensitivity reduces missed lesions (low FN), while high specificity reduces false alarms (low FP). The best balance depends on clinical context and downstream costs of errors.