Read the axes before the area

A ROC curve plots the true positive rate against the false positive rate across score thresholds. A precision–recall curve plots precision against recall over thresholds. In both views, recall is the share of actual positives the classifier finds. The other axis answers a different question: false positive rate uses actual negatives as its denominator, while precision uses all predicted positives.

Work through a rare event

Suppose a test set contains 100 positive cases and 9,900 negatives. At one threshold, a classifier finds 80 positives and raises 198 false alerts. Recall is 80%, the false positive rate is 2%, and precision is about 29% because only 80 of the 278 alerts are correct. This is one operating point, so these numbers cannot determine the area under either curve.

Compare curves on the same evaluation set

ROC AUC summarizes how well the scores rank positives above negatives across thresholds. A precision–recall summary draws attention to the share of useful alerts when positives are rare. Its baseline depends on the positive rate, 1% in the example dataset. Record that rate alongside the score and hold the evaluation data constant when comparing models.

Specify how PR performance was calculated

Tools may report trapezoidal area under the precision–recall curve or average precision. In scikit-learn, average precision weights the precision values by changes in recall. The figures can differ. Give the exact metric and calculation in a report so another person can reproduce the result. Use scores or probabilities for the curve and a separate threshold for the final yes-or-no decision.

Pick a threshold using the work it creates

Plot both curves on held-out data, then inspect how many alerts will reach the review team at realistic thresholds. At the example threshold, the team would review 278 records and miss 20 positives. If it can only review 150, compare models at the same review budget and report actual precision and recall there.

Related guides

Further reading. scikit-learn’s precision–recall documentation.