Bayes Theorem Calculator
Bayes’ theorem updates a prior probability after new evidence using the probability of that evidence under two competing conditions. It makes the effect of a low base rate visible instead of relying on sensitivity alone.
How to use this calculator
- Enter the prior probability, probability of positive evidence when the hypothesis is true, and false-positive probability when it is false.
- Check the labels and units before applying the result to a real task.
- Change one input at a time when comparing scenarios.
Formula and method
P(H|E) = P(E|H)P(H) ÷ [P(E|H)P(H) + P(E|¬H)P(¬H)]
- P(H|E) = P(E|H)P(H) ÷ [P(E|H)P(H) + P(E|¬H)P(¬H)]
- The result is only as reliable as the prior and conditional probabilities supplied. The tool does not determine whether a real-world model or diagnostic test is valid.
Worked examples
Worked example
Assume a 1% prior probability, 95% sensitivity, and a 5% false-positive rate.
Posterior after a positive result = 0.01×0.95 ÷ (0.01×0.95 + 0.99×0.05) ≈ 16.1%.
Posterior after a positive result = 0.01×0.95 ÷ (0.01×0.95 + 0.99×0.05) ≈ 16.1%.
Understanding the result
Bayes’ theorem updates a prior probability after new evidence using the probability of that evidence under two competing conditions. It makes the effect of a low base rate visible instead of relying on sensitivity alone.
The result is only as reliable as the prior and conditional probabilities supplied. The tool does not determine whether a real-world model or diagnostic test is valid.
Important notes
The result is only as reliable as the prior and conditional probabilities supplied. The tool does not determine whether a real-world model or diagnostic test is valid.
Displayed values are rounded for readability; retain appropriate precision when continuing a calculation.
Frequently asked questions
Why can a positive test still mean a low posterior probability?
When the prior condition is rare, false positives among the much larger unaffected group can account for many positive results. The prior and both conditional rates must be considered together.
What does sensitivity mean here?
Sensitivity is the probability of observing positive evidence when the condition or hypothesis is true, expressed as a percentage.
Can this calculator diagnose a medical condition?
No. It performs Bayes’ theorem arithmetic only and cannot validate a test, estimate a person’s prior risk, or replace qualified clinical interpretation.
Affiliate recommendations
Tools related to Bayes Theorem Calculator
These tools are selected for the calculator topic. The Calc Studio may earn a commission from purchases made through affiliate links.
- Growth Wise SAT & ACT prep Visit partner ↗
SAT and ACT study tools, flashcards, and preparation resources for students.
See the Affiliate Disclosure for details.
Related calculators
- Probability Calculator — Calculate simple event probability from favorable outcomes and total outcomes.
- Binomial Probability Calculator — Calculate the probability of exactly a chosen number of successes in independent trials with the same success probability.
- Pythagorean Theorem Calculator — Find the hypotenuse of a right triangle from the two perpendicular sides.
- 2×2 Matrix Calculator — Add, subtract and multiply 2×2 matrices and calculate each determinant with transparent row and column inputs.
- Normal Distribution Calculator — Estimate probability below, between or above two values for a normal distribution with a chosen mean and spread.
- Circle Calculator — Calculate circle area, circumference, and diameter from radius.
Related explanations
Learn the method behind the number or compare the terminology before using the calculator.
- How to Calculate Probability — Learn basic probability formulas, complementary probability, and how to calculate simple event chances.
- How to Calculate Percent Error — Learn the percent error formula and how to compare an experimental value with a reference or accepted value.
- Probability — Understand probability as a measure of how likely an event is and review simple probability formulas.
This page provides a calculation tool plus explanatory information so you can understand what the result means and when the underlying method may not fit your situation.