Processing math: 100%

The Posterior Mode of Beta Distribution

This article answers Exercise 4.14 from the highly recommended Bayes Rules! book.

img1

Figure 1Figure 1: The Bechdel Test. Image taken from Wikipedia.

In Chapter 4 of the book, recall that the Bechdel test is satisfied by a movie whose conditions are as follows:

  • the movie has at least two women in it,
  • these two women talk to each other, and
  • the two women also talk about something other than a man.

Furthermore, Figure 1 summarizes the three rules mentioned before.

Suppose that we review a sample of n recent movies and record Y, the number of movies that pass the Bechdel test. Considering Y as the number of “successes” in a fixed number of independence trials, Y can be specified as a Binomial model with π as its parameter. Moreover, π can also be described as Beta distribution with prior hyperparameters α and β:

YπBin(n,π)πBeta(α,β).

Thus, the posterior of Beta-Binomial model of π is given by

π(Y=y)Beta(α+y,β+ny).

The Question:

In the Beta-Binomial setting, show that we can write the posterior mode of π as the weighted average of the prior mode and observed sample success rate: Mode(πY=y)=α+β2α+β+n2Mode(π)+nα+β+n2yn

Answer:
Recall that mode of the prior is

Mode(π)=α1α+β2

and mode of the posterior is

Mode(πY=y)=α+y1α+β+n2.

Next, we show that Equation (4) can be written as Equation (2) as follows:

Mode(πY=y)=α+y1α+β+n2=α1α+β+n2+yα+β+n2=α1α+β+n2α+β2α+β2+yα+β+n2nn=α+β2α+β+n2α1α+β2+nα+β+n2ynRearrange the terms=α+β2α+β+n2Mode(π)+nα+β+n2yn.Utilize Equation (3)

At last, we have shown that Equation (2) is indeed true.


Written on December 30, 2021