Calculator Results
Precision-Recall Curves
Recall appears on the horizontal axis. Precision appears on the vertical axis. Hover over points to inspect thresholds.
Selected Operating Point
Confusion Matrix
Model Comparison
| Rank | Model | PR AUC | Average Precision | Unweighted AP | Lift vs Baseline | Best Threshold | Precision | Recall | F-score |
|---|
| Threshold | TP | FP | TN | FN | Precision | Recall | F-score | Accuracy | Specificity |
|---|
Formula Used
Precision = TP / (TP + FP) Recall = TP / (TP + FN) Fβ = (1 + β²) × Precision × Recall / (β² × Precision + Recall) Specificity = TN / (TN + FP) Accuracy = (TP + TN) / (TP + FP + TN + FN) PR AUC = area under the Precision-Recall curve Average Precision = Σ (Recallᵢ − Recallᵢ₋₁) × Precisionᵢ
How to Use
- Enter actual labels and one prediction-score list.
- Add more models when comparative analysis is required.
- Optionally enter sample weights or import CSV columns.
- Select threshold generation and optimization settings.
- Click calculate to create curves and detailed tables.
- Inspect the selected threshold and confusion matrix.
- Export results as CSV, PDF, PNG, or copied text.
Example Data
| Observation | Actual Label | Model A Score | Model B Score | Weight |
|---|---|---|---|---|
| 1 | 1 | 0.95 | 0.88 | 1 |
| 2 | 0 | 0.82 | 0.61 | 1 |
| 3 | 1 | 0.78 | 0.83 | 2 |
| 4 | 0 | 0.43 | 0.55 | 1 |
| 5 | 1 | 0.67 | 0.72 | 1 |
Interpretation Guide
Precision measures how many positive predictions are correct. Recall measures how many actual positives are detected. Their balance depends strongly on the selected threshold.
A Precision-Recall curve is especially useful for imbalanced datasets. Its baseline equals the positive-class prevalence. Curves above that baseline indicate useful ranking performance.
Average Precision summarizes step-wise precision across recall gains. PR AUC uses numerical integration between curve points. The two values can differ slightly.
Frequently Asked Questions
What is a Precision-Recall curve?
It plots precision against recall across decision thresholds.
Why use it for imbalanced data?
It focuses directly on positive-class prediction quality.
What is the no-skill baseline?
It equals the weighted positive prevalence in the dataset.
What does Average Precision measure?
It summarizes precision over successive increases in recall.
How does beta affect F-score?
Lower beta favors precision, while higher beta favors recall.
Can prediction scores exceed one?
Yes, when unrestricted validation is selected for decision scores.
Can I compare several models?
Yes. Add score lists or choose multiple CSV columns.
Are sample weights supported?
Yes. Weighted confusion counts and metrics are calculated.
How is the optimal threshold chosen?
It follows your selected F-score, constraint, cost, or weighted rule.