Bayes Theorem Calculator
Calculate a posterior probability for two exhaustive hypotheses using supplied likelihoods.
Result for the values shown.
Calculations run in your browser.
What to enter
| Input | Meaning and units |
|---|---|
| Prior probability of A | Enter prior probability of a using the definition in the method and example. |
| Probability of evidence given A | Enter probability of evidence given a using the definition in the method and example. |
| Probability of evidence given not A | Enter probability of evidence given not a using the definition in the method and example. |
Understanding your result
These outputs describe the probability model and event definitions you entered. A probability is a number from 0 to 1; a probability density is not itself the probability of one exact continuous value.
Common mistakes
- Entering 25 instead of 0.25 for a probability, or assuming events are independent when the model requires that assumption.
- Confusing an exact-count probability with a cumulative probability, or replacement with sampling without replacement.
Check your calculation
- Check a zero/certain-event boundary and the stated support of the distribution against the worked example.
Calculation checks, sources and review limits
How should my prior probability change after seeing this evidence?
Calculate a posterior probability for two exhaustive hypotheses using supplied likelihoods.
Common uses
- How should my prior probability change after seeing this evidence
How it works
evidence = likelihood * prior + alternative * (1 - prior); posterior = likelihood * prior / evidence
Worked example
Enter Prior probability of A: 0.1 ; Probability of evidence given A: 0.8 ; Probability of evidence given not A: 0.2 . Results: Probability of evidence: 0.26 ; Posterior probability of A: 0.3076923076923077 .