CSE 575 Beta Distribution In-class Exercises

Below are the 3 exercise problems discussed in class regarding the Beta Distribution. Going through all of these may greatly help you with understanding important concepts, and, at least, preparing for the first midterm exam.

Exercise 1 - Derivation of conjugate distribution

Coin flip. Bernoulli Trials. Derive that the posterior and prior distributions are conjugate distributions, or, more explicitly, show that both are Beta distributions.

Derivation

Suppose we’ve already known that the prior and the posterior . and denote the parameter and the observation, and and the numbers of heads and tails from the observation, respectively.

So for the product of the prior and the likelihood, we have

Since , we may use a constant to simplify the proportion, and thus

Joining (1) and (2) up, and since is a constant as well, we can derive that

And thus the expectation of the posterior is

Exercise 2 - Given prior and observations

Coin flip. Given the prior pdf , we observe 2 heads and 2 tails. What is the posterior pdf? What is the MLE and what is the MAP ?

Direct Answers

Using (3), it’s easy to get the posterior distribution as

Recall that asks for what makes observing the most likely. Thus

And also recall that is the most likely value in the posterior distribution (aka the peak of the pdf). So

What if…

Now, what if we observe 20 heads and 20 tails?

Or 200 heads and 200 tails?

You may discover that and are converging if the observation is large enough.

Exercise 3 - Given prior and posterior

Given the prior and the posterior , what is the observation (aka what are and )?

Answer

So we have , , as well as and . Now this is easy.

Some after-thoughts

  1. The prior distribution is the experience, some model that others use to describe a phenomenon.

  2. The posterior is built upon your own observations AND the experience/prior. Technically you adjust the model in order to fit with your own findings. And that is what the posterior is all about.

Written on February 2, 2018