Likelihood Ratio Calculator

Enter your test's sensitivity and specificity (or the raw confusion matrix values TP, FP, FN, TN) to calculate the Positive Likelihood Ratio (LR+) and Negative Likelihood Ratio (LR−). You also get post-test probability when you supply a pre-test probability. Switch between input modes depending on what data you have available.

%

Proportion of true positives correctly identified (0–100%)

%

Proportion of true negatives correctly identified (0–100%)

Patients with disease who test positive

Patients without disease who test positive

Patients with disease who test negative

Patients without disease who test negative

%

Prevalence or clinical estimate of disease probability before testing (0–100%)

Results

Positive Likelihood Ratio (LR+)

--

Negative Likelihood Ratio (LR−)

--

Sensitivity

--

Specificity

--

Post-test Probability (Positive Test)

--

Post-test Probability (Negative Test)

--

LR+ Interpretation

--

Likelihood Ratios (LR+ vs LR−)

Frequently Asked Questions

What is a likelihood ratio in medical testing?

A likelihood ratio (LR) tells you how much a test result changes the probability of a diagnosis. The positive likelihood ratio (LR+) indicates how much more likely a positive result is in someone with the disease compared to someone without it. The negative likelihood ratio (LR−) indicates how much less likely a negative result is in someone with the disease.

How is the Positive Likelihood Ratio (LR+) calculated?

LR+ is calculated as Sensitivity ÷ (1 − Specificity). For example, if sensitivity is 85% and specificity is 90%, then LR+ = 0.85 ÷ 0.10 = 8.5. A higher LR+ (ideally >10) indicates a test is good at ruling in a disease.

How is the Negative Likelihood Ratio (LR−) calculated?

LR− is calculated as (1 − Sensitivity) ÷ Specificity. Using the same example: LR− = 0.15 ÷ 0.90 ≈ 0.167. A lower LR− (ideally <0.1) means a negative result is strong evidence against the disease.

What LR values indicate a clinically useful test?

As a general rule: LR+ > 10 or LR− < 0.1 provides strong diagnostic evidence; LR+ 5–10 or LR− 0.1–0.2 provides moderate evidence; LR+ 2–5 or LR− 0.2–0.5 provides small but sometimes useful shifts; and LR values near 1 indicate a test with little diagnostic value.

How do I calculate post-test probability from a likelihood ratio?

First convert pre-test probability to pre-test odds: Odds = Probability ÷ (1 − Probability). Then multiply by the LR to get post-test odds. Finally convert back: Post-test Probability = Post-test Odds ÷ (1 + Post-test Odds). This is an application of Bayes' theorem.

Can I calculate likelihood ratios from a confusion matrix?

Yes. From the 2×2 matrix, Sensitivity = TP ÷ (TP + FN) and Specificity = TN ÷ (TN + FP). Once you have sensitivity and specificity, the LR+ and LR− formulas apply as normal. This calculator supports direct entry of TP, FP, FN, and TN values.

What is the difference between sensitivity, specificity, and likelihood ratios?

Sensitivity and specificity are fixed properties of a test but cannot directly account for prevalence. Likelihood ratios combine both metrics into a single value and allow you to update disease probability via Bayes' theorem for any given pre-test probability, making them more clinically actionable.

Why might the likelihood ratio be undefined or very large?

LR+ becomes undefined when specificity equals 100% (denominator = 0), and LR− becomes undefined when sensitivity equals 100%. Extremely high LR+ values occur with very high specificity. These edge cases are mathematically valid but may reflect overfitting in small datasets.

More Statistics Tools