I am looking at the Wikipedia entry for empirical Bayes, but it's a bit confusing - it seems to me the solution must apply only to the case in which there's only $n=1$ sample $y$ for each $\theta$ and the "sample mean" that's referred to is really just a single value. If this were not the case, I would think that the shrinkage factors would depend on the sample size for each $\theta$.

What if I want to generalize this to where there are multiple samples of $y$ for each Poisson mean $\theta$? Is this the formula for the posterior on $\theta_k$ (the Poisson mean for the $k^{\rm th}$ group): $$ \theta_k = \frac n {(n + \beta)} \times \text{sample_mean}(y_k) + \frac \beta {(n + \beta)} \times (\alpha \times \beta) $$ if so what's the derivation for this?

  • $\begingroup$ Welcome to the site, @user44285. I took the liberty of editing your post & trying to use the site's $\LaTeX$ markup features to make your equation more readable. Please ensure it still says what you want it to. $\endgroup$ – gung Apr 23 '14 at 2:20
  • $\begingroup$ thanks, i made a correction to my guess. the wikipedia example is strange and i'm starting to wonder if it has a typo $\endgroup$ – user44285 Apr 23 '14 at 3:14

It appears you are correct that there is an error on wikipedia and their formula only applies when n=1, but your formula is not correct either. If you had multiple observations for each $\theta_k$, then you could derive the posterior for each $\theta_k$ to be

$ p( \theta_k \vert Y_{k1},...,Y_{kn}) \sim gamma(\alpha + \sum_i Y_{ki}, (n + 1/\beta)^{-1}) $

$ E( \theta_k \vert Y_{k1},...,Y_{kn}) = \frac{\alpha + \sum_i Y_{ki}}{n + 1/\beta} = \bar{Y}_k\frac{n\beta}{n\beta+1} + \alpha\beta\frac{1}{n\beta+1} $


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.