Calculator Inputs
Visualization
The chart compares single-run detection behavior and optional batch scenarios.
Example Data Table
| Scenario | True Positives | False Negatives | Actual Positives | TPR |
|---|---|---|---|---|
| Fraud Model A | 82 | 18 | 100 | 0.8200 |
| Fraud Model B | 90 | 10 | 100 | 0.9000 |
| Fraud Model C | 74 | 26 | 100 | 0.7400 |
Formula Used
True Positive Rate measures how many real positive cases were correctly detected.
TPR = TP / (TP + FN)
Where TP means true positives and FN means false negatives.
The companion error metric is FNR = FN / (TP + FN). In classification work, TPR is also called sensitivity or recall.
How to Use This Calculator
- Enter the model name to identify the result set.
- Provide true positives and false negatives from your confusion matrix.
- Add optional population size and prevalence to estimate detected cases.
- Enter a threshold if you want to compare operating points.
- Paste batch lines in
label,tp,fnformat for scenario analysis. - Press the calculate button to show results above the form.
- Use the CSV or PDF buttons to export the report.
Frequently Asked Questions
1. What does true positive rate mean?
It shows the share of actual positive cases your model correctly identifies. A higher value means fewer missed positives and stronger sensitivity for the chosen threshold.
2. Is true positive rate the same as recall?
Yes. In many data science workflows, true positive rate, recall, and sensitivity all refer to the same quantity: TP divided by actual positives.
3. Why can a high true positive rate still be risky?
A model may detect most positives yet also create many false alarms. You should review false positive rate, precision, and business impact together.
4. What inputs are required here?
Only true positives and false negatives are required. Population, prevalence, threshold, and batch scenarios are optional support inputs for planning and comparison.
5. How does prevalence affect interpretation?
Prevalence does not change true positive rate directly. It helps estimate how many real positive cases exist in a larger population and how many may be detected.
6. What happens if TP plus FN equals zero?
The rate becomes undefined because there are no actual positive cases to evaluate. This calculator avoids division by zero and prompts careful review.
7. Why include batch scenario analysis?
Batch mode helps compare several models, thresholds, or testing periods at once. That makes it easier to choose stronger detection settings.
8. Can I use this for medical or fraud models?
Yes. The formula is general and works for diagnostics, fraud screening, anomaly detection, spam filtering, and many other binary classification tasks.