# Find the posterior distribution for an exponential prior and a Poisson likelihood

I have a prior $\lambda \sim \exp(1)$ and a likelihood $X \sim poisson(\lambda)$, and I observed in a sample of $n=5$ a mean of $3$. What is the posterior distribution of $\lambda$?

Here is my asnwer:

$f(x|\lambda) = \frac{\lambda^{x}e^{-\lambda}}{x!}$ $f(\lambda) = \theta e^{-\theta \lambda}, \theta = 1 => f(\lambda) = e^{-\lambda }$

So, the posterior:

$f(\lambda|x) \propto e^{-\lambda} \lambda^{x} e^{-\lambda +(-\lambda)} = \lambda^{x}e^{-2 \lambda}$

This posterior is some known distribution (e.g. exponential)?

• Since the standard (and standardized) procedure fully applies, you might want to explain what is causing you trouble here. (Furthermore, note that stricto sensu you asked no question.) – Did May 28 '13 at 5:55
• I have done the calculations but I don't know it my results are right. I would like to know if this posterior would be some know probability distribution (conjugate or not). – Filipe Ferminiano May 31 '13 at 20:07
• I have done the calculations but I don't know it my results are right... Then show them instead of leaving everybody in the blue. – Did May 31 '13 at 23:20
• Ok, I edited my post. Take a look please. – Filipe Ferminiano Jun 1 '13 at 13:04
• Which part of my answer is not the standardized procedure I alluded to in my first comment and, retrospectively, was causing you problems? – Did Jun 1 '13 at 16:34

Assume one observed $x=(x_k)_{k\leqslant n}$, then $f(x\mid\lambda)=f(x_1\mid\lambda)\cdots f(x_n\mid\lambda)\propto\lambda^{|x|}\mathrm e^{-n\lambda}$ where $|x|=x_1+\cdots+x_n$ and $\propto$ refers to the fact that one omits multiplicative constants independent of $\lambda$. Thus, $f(\lambda\mid x)\propto f(\lambda)f(x\mid\lambda)\propto\lambda^{|x|}\mathrm e^{-(n+1)\lambda}$. To find the normalizing constant, recall that, for every positive $u$ and $v$, $$\int_0^\infty\lambda^{u-1}\mathrm e^{-v\lambda}\mathrm d\lambda=v^{-u}\Gamma(u),$$ hence, finally, $$f(\lambda\mid x)=(n+1)^{-|x|-1}\,(|x|)!\,\lambda^{|x|}\mathrm e^{-(n+1)\lambda}.$$ This is the gamma distribution with parameters $(n+1,|x|+1)$.
$f(\lambda|x) \propto \lambda^x \cdot \exp(-2\lambda)= \lambda^{(x+1)-1} \cdot \exp(-2\lambda)$.
This is a Gamma density with parameters $x+1,-2$, ie Gamma($\lambda|x+1,-2$)
• Since the exponential is a special case of Gamma ie Gamma(1,$\lambda$) we do have conjugacy. – theoGR Jul 21 '16 at 21:30