Sylvics Apply for the beta
📐 Bayes' ruleFormula
FORMULA

🚕Bayes' rule

🚦 Status🗂️ Library
🏷️ Topics
formulamathprobability
🏷️ CategoryTheorem
❤️ Favorite⭐ Favourite

📐FORMULA

$$P(H \mid E) = \frac{P(E \mid H),P(H)}{P(E)}$$

  • P(H): the 🔤 Prior, what I believed about the hypothesis before the evidence
  • P(E | H): the likelihood, how probable this evidence is if the hypothesis is true
  • P(E): the evidence, how probable it is overall: P(E | H) P(H) + P(E | not H) P(not H)
  • P(H | E): the posterior, what I should believe now

Posterior equals prior times likelihood, over evidence. The denominator is only there to make the answers add up to one.

The taxi. A cab is involved in a hit-and-run at night. 85 percent of the city's cabs are Green and 15 percent are Blue. A witness says the cab was Blue, and when tested under the same conditions the witness names the colour correctly 80 percent of the time.

  • Prior that it was Blue: 0.15
  • Witness says Blue and it was Blue: 0.15 × 0.80 = 0.12
  • Witness says Blue and it was Green: 0.85 × 0.20 = 0.17
  • Posterior: 0.12 / (0.12 + 0.17) = 0.12 / 0.29 ≈ 0.41

So after a fairly reliable witness says Blue, Green is still the better bet. Everyone in the room said 80 percent, me included, which is what ignoring the base rate sounds like.

Odds form, which I find easier on a tram: prior odds 15 to 85, likelihood ratio 0.80 / 0.20 = 4, posterior odds 60 to 85, and 60 / 145 ≈ 0.41 again.

It landed twice: once on the whiteboard in 🎓 Lecture 14 - Updating beliefs with Bayes, and once as a picture, the square cut into strips, in 🎬 Bayes theorem, the geometry of changing beliefs. Then I typed it out as Bayes update on a grid and watched the posterior move.

Last checked by hand on 28 October, both ways round, and both gave 0.41.

🔗LINKED FROM