Choosing a Decision Threshold
Selecting decision probability thresholds to balance Precision, Recall, and business financial loss.
Beyond the Default 0.50 Threshold
Binary classification models do not output hard predictions like Yes or No.
They output a continuous probability score $\hat{p} \in [0.0, 1.0]$.
By default, software frameworks apply a Default Decision Threshold of 0.50:
$$\text{Prediction} = \begin{cases} \text{Positive} & \text{if } \hat{p} \ge 0.50 \ \text{Negative} & \text{if } \hat{p} < 0.50 \end{cases}$$
In real world engineering, the 0.50 threshold is almost never optimal!
Lower Threshold (0.10): High Recall (Catches almost all positives, many false alarms).
Default Threshold (0.50): Equal balance (Rarely matches true business costs).
Higher Threshold (0.85): High Precision (Very conservative, high confidence required).
How to Select the Optimal Threshold
┌──────────────────────────┬──────────────────────────┬──────────────────────────┐
│ 1. PR-CURVE (F-BETA) │ 2. COST MATRIX │ 3. YOUDEN J STATISTIC │
├──────────────────────────┼──────────────────────────┼──────────────────────────┤
│ Optimize F-beta score │ Assign monetary dollar │ Maximize (Sensitivity + │
│ based on business preference| cost to FP and FN; pick │ Specificity - 1) on ROC │
│ for Precision or Recall. │ profit-maximizing cutoff!│ curve. │
└──────────────────────────┴──────────────────────────┴──────────────────────────┘
1. Cost Sensitive Financial Optimization
Assign explicit financial dollar costs to errors:
- $C_{\text{FP}}$: Cost of a False Positive (for example $$5$ support call to unblock a flagged credit card).
- $C_{\text{FN}}$: Cost of a False Negative (for example $$500$ lost to an unblocked fraudulent charge).
Calculate Total Financial Cost across candidate thresholds $\tau$:
$$\text{Total Cost}(\tau) = C_{\text{FP}} \cdot \text{FP}(\tau) + C_{\text{FN}} \cdot \text{FN}(\tau)$$
Select threshold $\tau^*$ that minimizes Total Financial Cost.
2. Tuning via $F_{\beta}$ Score
If monetary costs are unknown, use the $F_{\beta}$ Score:
$$F_{\beta} = (1 + \beta^2) \frac{\text{Precision} \times \text{Recall}}{(\beta^2 \times \text{Precision}) + \text{Recall}}$$
- Set $\beta = 2.0$ when Recall is more important (Cancer detection, Fraud).
- Set $\beta = 0.5$ when Precision is more important (Email spam filtering, Search top results).
Say this out loud
Decision threshold selection converts predicted probability scores into final classification actions. Raising thresholds increases precision by reducing false positives, while lowering thresholds increases recall by reducing false negatives. Engineering teams select thresholds using financial cost matrices, F-beta optimization, or Precision-Recall curves rather than defaulting to 0.50.
Followups to expect
- How does threshold selection interact with probability calibration? Uncalibrated probabilities distort threshold selection. Calibrating raw probabilities using Platt Scaling or Isotonic Regression ensures threshold cutoffs reflect true empirical probabilities.
- What is Precision-Recall Curve vs ROC Curve for threshold tuning? Use PR curves when working with heavily imbalanced datasets, as ROC curves can give overly optimistic impressions of model performance.
Check yourself
What happens to Precision and Recall when you INCREASE a binary classification probability threshold from 0.50 to 0.85?