Link: Bayesian statistics Prior probability and posterior probability Conditional probabilities
What is Bayes’ theorem?
Bayes’ theorem is the basics for Bayesian statistics.
The equation:
where:
- = the prior probability of A occurring
- = the conditional probability of A, given that B occurs
- = the conditional probability of B, given that A occurs
- = the probability of B occurring
Derive Bayes’ theorem
A simple example
Chance of a medical condition with test result
- Prior Probability : Initial belief about having the medical condition before taking the test. E.g. 2% chance (0.02) of having a condition based on symptoms and family history.
- Likelihood : The probability that the test is positive given that you actually have the condition. E.g. 95% (assuming the test is pretty accurate)
- Total Evidence : The overall probability of getting a positive test result, taking into account both scenarios: having the condition (A) and not having it . So:
If we apply Bayes’ theorem:
- : the updated probability of actually having the condition after getting a positive test result
Summary
It means we can get posterior probability based on prior probability, likelihood, and total evidence.