Module 15 of 16 · Maths and Statistics in AI · Beginner

Bayes' Theorem and Bayesian Statistics

Duration: 6 min

Bayes' Theorem

Formula

P(A|B) = P(B|A) × P(A) / P(B)

Where:

Intuition

Example: Medical Testing

Suppose:

If test is positive, what's probability of having disease?

P(Disease|Positive) = P(Positive|Disease) × P(Disease) / P(Positive)
                    = 0.95 × 0.01 / (0.95×0.01 + 0.10×0.99)
                    ≈ 0.087 or 8.7%

Despite positive test, only ~9% chance of disease (due to low prevalence)

Bayesian vs Frequentist Statistics

Frequentist

Bayesian

Prior, Likelihood, Posterior

  1. Prior: Initial belief before data
  2. Likelihood: How likely data is under each hypothesis
  3. Posterior: Updated belief after observing data

Updating Process

Posterior ∝ Likelihood × Prior

Conjugate Priors

Bayesian Inference

Point Estimation

Credible Intervals

Applications in AI/ML

Naive Bayes Classifier

Bayesian Networks

Bayesian Optimization

❓ In Bayes' theorem, what is P(A)?

← Previous Continue interactively → Next →

Related Courses