Diagnostic accuracy: sensitivity, specificity, ROC
Quantifies how well a new test identifies patients with the condition, compared with a reference standard.
Clinical example
A rapid blood test for myocardial infarction compared with the final clinical diagnosis in patients who presented with chest pain.
When to use it
- You compare a new test with a reference standard in the same patients.
- The test result is yes or no, or a continuous value.
- You want sensitivity and specificity and, for a continuous test, the ROC curve.
Assumptions to check
Appropriate reference standard
The reference standard should be as close to the truth as practical, and applied to all patients regardless of the test result.
Representative spectrum of patients
Accuracy depends on who is tested. Include patients like those in whom the test will be used.
What to report
- The 2x2 table against the reference standard
- Sensitivity and specificity with 95% CI
- AUC with 95% CI for a continuous test
- The threshold used, and whether it was set in advance
Common mistakes
Report the effect, not just the p-value
Give the estimate (difference, ratio) with its 95% confidence interval and the exact p-value.
In your software
# R
library(pROC)
roc_obj <- roc(d$reference, d$test_value)
plot(roc_obj)
ci.auc(roc_obj)
ROC test_value BY reference (1)
/PLOT=CURVE(REFERENCE)
/PRINT=SE COORDINATES
/CRITERIA=CUTOFF(INCLUDE) TESTPOS(LARGE) DISTRIBUTION(FREE) CI(95).