What is a ROC Curve?

A ROC curve plots the performance of a binary classification model at all classification thresholds. It shows the trade-off between sensitivity and specificity.

X-axis: False Positive Rate (FPR)
Y-axis: True Positive Rate (TPR)
TPR = TP / (TP + FN) = Sensitivity
FPR = FP / (FP + TN) = 1 - Specificity

AUC (Area Under Curve) summarizes the entire ROC curve into a single number between 0 and 1.

ROC Curve Example

False Positive Rate True Positive Rate 0.0 0.5 1.0 0.0 0.5 1.0 Good Classifier (AUC ≈ 0.85) Perfect Classifier (AUC = 1.0) Random Guess (AUC = 0.5)

The closer the curve is to the top-left corner, the better the classifier