Two patient cohorts each produce a continuous biomarker reading. Diseased readings follow N(μd, σ²), healthy readings follow N(μh, σ²). A single cutoff c turns the continuous value into a binary test:
Sensitivity = P(value > c | diseased) = 1 − Φ((c − μ_d) / σ)
Specificity = P(value ≤ c | healthy) = Φ((c − μ_h) / σ)
PPV = TP / (TP + FP) (from the drawn sample)
AUC = Φ( (μ_d − μ_h) / (σ√2) )
Φ is the standard normal CDF. Sensitivity and specificity move in opposite directions as the cutoff slides — dragging it right trades false positives for false negatives. The two population clouds are drawn as real random samples (Box–Muller Gaussian draws); the confusion matrix, sensitivity, specificity and PPV are computed directly by counting where each sampled point falls relative to the cutoff plane. AUC is the probability a randomly picked diseased case scores higher than a randomly picked healthy case — with equal-variance Gaussians it has the closed form above, independent of sample noise.
- Threshold — slides the translucent cutoff plane along the concentration axis.
- Separation — how far apart the two population means sit; larger Δμ means a more useful biomarker.
- Spread — the shared standard deviation; more overlap makes any single cutoff less decisive.
- Sample size — how many simulated patients are drawn per group.
This is the same trade-off behind real diagnostic cutoffs — troponin for a heart attack, PSA for prostate cancer, HbA1c for diabetes — where moving the decision threshold always trades sensitivity against specificity.