Formula Used
The basic posterior probability formula is:
P(H|E) = [P(E|H) × P(H)] / P(E)
For a binary hypothesis, the evidence term is:
P(E) = [P(E|H) × P(H)] + [P(E|not H) × P(not H)]
For repeated independent positive and negative evidence, this calculator uses:
P(data|H) = P(E|H)^positive × P(not E|H)^negative
P(data|not H) = P(E|not H)^positive × P(not E|not H)^negative
The Bayes factor is:
Bayes Factor = P(data|H) / P(data|not H)
How to Use This Calculator
- Enter a short hypothesis label, such as “customer will buy”.
- Select percent or decimal input scale.
- Enter the prior probability before seeing new evidence.
- Enter P(E|H), the evidence likelihood when the hypothesis is true.
- Enter P(E|not H), the evidence likelihood when the hypothesis is false.
- Add positive and negative evidence counts.
- Set a decision threshold for your action rule.
- Submit the form and review the posterior result above the form.
- Use the CSV or PDF buttons to export the calculation.
Example Data Table
| Scenario |
Prior |
P(E|H) |
P(E|not H) |
Positive |
Negative |
Approx Posterior |
| Fraud alert |
5% |
82% |
10% |
1 |
0 |
30.15% |
| Medical screening |
2% |
95% |
6% |
1 |
0 |
24.43% |
| Quality defect |
8% |
90% |
15% |
2 |
0 |
75.75% |
| Spam filter |
25% |
88% |
20% |
1 |
1 |
8.17% |
Posterior Probability Guide
Why Posterior Probability Matters
Posterior probability is the updated chance that a hypothesis is true after new evidence appears. It is useful when the first estimate is uncertain. A doctor may start with a disease rate. A marketer may start with a conversion rate. A quality analyst may start with a defect rate. New test results, signals, or observations then change that belief.
A Practical Bayesian Update
This calculator applies Bayes theorem to a binary hypothesis. You enter the prior probability, the likelihood of evidence when the hypothesis is true, and the likelihood of the same evidence when it is false. The tool also supports repeated positive and negative observations. That helps when several independent tests, clicks, alerts, or inspections are available.
Reading The Result
The posterior result is not just a percentage. It is a structured update. A strong likelihood ratio pushes the prior upward. A weak ratio moves it only a little. Negative evidence can reduce the probability. The odds view helps compare before and after values. The chart makes this movement easier to see.
Common Use Cases
Posterior probability is used in statistics, medicine, machine learning, auditing, risk scoring, and decision science. It is also useful for spam filtering, fraud checks, A/B testing, and reliability studies. The method works best when likelihoods are estimated from trustworthy data. Poor likelihoods produce poor updates.
Good Inputs Matter
Use a realistic prior. Avoid guessing without context. Estimate sensitivity and false positive rates from historical samples when possible. Keep repeated evidence independent. When observations are correlated, the posterior may become too confident. Review assumptions before making final decisions.
Using The Downloads
The CSV export helps store numeric results. The PDF option creates a simple report for sharing. The example table shows typical inputs and outcomes. Use it as a learning guide, not as a universal rule.
Decision Tips
Treat the answer as evidence based support. It should guide judgment, not replace it. Compare the posterior with your action threshold. For example, a high risk alert may need review. A low risk signal may need monitoring. Document each input source. This makes later audits easier and improves trust for every reader.
FAQs
1. What is posterior probability?
Posterior probability is the updated probability of a hypothesis after considering new evidence. It combines the prior probability with evidence likelihoods using Bayes theorem.
2. What is a prior probability?
A prior probability is the starting chance before new evidence is included. It should come from history, expert judgment, base rates, or earlier data.
3. What does P(E|H) mean?
P(E|H) means the chance of seeing the evidence if the hypothesis is true. It measures how sensitive the evidence is to the true condition.
4. What does P(E|not H) mean?
P(E|not H) means the chance of seeing the same evidence when the hypothesis is false. Smaller values usually make positive evidence stronger.
5. What is a Bayes factor?
A Bayes factor compares how likely the evidence is under two competing cases. Values above one support the hypothesis. Values below one weaken it.
6. Can I use repeated evidence?
Yes. This calculator supports repeated positive and negative evidence. It assumes observations are independent, so correlated evidence should be used carefully.
7. Why can the posterior stay low after strong evidence?
A very low prior can keep the posterior modest. Strong evidence helps, but rare events often need highly reliable evidence to become likely.
8. Is this calculator suitable for final decisions?
It supports decisions, but it should not replace expert review. Check assumptions, data quality, independence, costs, and consequences before acting.