3. Suppose that a proportion parameter $\theta$ has a Beta(a, b) prior and one observes
$y_1,..., y_n$ from a Bernoulli distribution with parameter $\theta$, then the posterior
density of $\theta$ is Beta(a + y, b + n - y).
Show that the posterior mean of $\theta$ | Y = y ~ Beta(a + y, b + n - y) is a
weighted average of the prior mean of $\theta$ ~ Beta(a, b) and the sample mean
$\hat{\theta} = \frac{y}{n}$. Find the two weights and explain their implication for the posterior
being a combination of prior and data. Comment how Bayesian inference
allows collected data to sharpen one's belief from prior to posterior.