Bayes' Theorem Calculator

Compute posterior probability from prior, sensitivity, and false positive rate with scenario presets.

Scratchpad (not saved)

What This Calculator Does

This calculator applies Bayes' theorem to update a prior belief after observing evidence such as a positive test, spam flag, or alarm. It includes presets to illustrate how the same test accuracy leads to very different posteriors when the base rate changes.

It combines Preset, Prior Probability, Sensitivity / Likelihood, False Positive Rate to estimate Posterior Probability, P(B), False Negative Rate.

Formula & Method

Core equations: P(A|B)=\frac{P(B|A)P(A)}{P(B|A)P(A)+P(B|\neg A)P(\neg A)}.

Notation used in the formulas: R = Posterior Probability; x_{1} = Preset; x_{2} = Prior Probability; x_{3} = Sensitivity / Likelihood; x_{4} = False Positive Rate.

Method summary: inputs are normalized to consistent units, core equations are evaluated, then secondary values are derived and rounded for display.

Use it when the prior probability matters and you need the posterior probability instead of the raw sensitivity or false positive rate, especially for screening and classifier outputs.

Inputs Used

  • Preset: Used directly in the calculation.
  • Prior Probability: Used directly in the calculation.
  • Sensitivity / Likelihood: Used directly in the calculation.
  • False Positive Rate: Used directly in the calculation.

Related Calculators