Statistics
Intermediate
9 min

Bayesian Updating with Conjugate Priors

A Beta(a,b) prior on a probability updates to Beta(a+successes, b+failures) after observing Bernoulli data.

1. The idea

Bayesian updating combines a prior belief about a parameter with observed data to get a posterior belief, via .

The Beta distribution is the conjugate prior for a Bernoulli/binomial success probability: if the prior is and you observe successes and failures, the posterior is exactly — no integration required.

This gives a natural interpretation of and as 'pseudo-counts' of prior successes and failures, and the update rule is simply adding the observed counts to them.

2. Why it matters

Conjugate updating is the fastest way to reason about probability estimation under uncertainty — a recurring theme in A/B testing and sequential decision-making interview questions.

3. Core mathematics

Beta-Bernoulli conjugacy

Posterior mean

4. How to recognize it

Think of this when…

  • Prior on a probability is stated as Beta(a,b) or as 'uniform prior' (Beta(1,1))
  • You observe a sequence of successes/failures and want an updated belief
  • Question asks for a posterior mean or how confidence should shift after new data

5. Worked example

Worked example

A coin's bias has a Beta(2,2) prior. You observe 8 heads and 2 tails in 10 flips. Find the posterior distribution and its mean.

  1. 1

    Apply the conjugate update rule: add observed successes to and failures to .

  2. 2

    Compute the posterior mean using the Beta mean formula .

  3. 3

    Simplify.

  4. Answer: Posterior is Beta(10,4), mean

6. Common mistakes

  • Adding failures to and successes to instead of the correct assignment
  • Forgetting that Beta(1,1) is the uniform prior on [0,1]
  • Computing the posterior mean with the prior's instead of the updated ones
  • Treating the posterior as a point estimate rather than a full distribution with its own variance

7. Quick check

Starting from a Beta(1,1) prior and observing 3 successes and 1 failure, what is the posterior?

8. Practice

5 QuantSolve questions use this concept.

Practice this concept

9. Related methods