# Gamma/Poisson Distribution- Probability

• Jan 19th 2008, 11:19 PM
shilz222
Gamma/Poisson Distribution- Probability
Let $\displaystyle Y$ be a gamma random variable with parameters $\displaystyle (s, \alpha)$. That is, its density is $\displaystyle f_{y}(y) = Ce^{- \alpha y}y^{s-1}, y > 0$, where $\displaystyle C$ is a constant that does not depend on $\displaystyle y$. Suppose also that the conditional distribution of $\displaystyle X$ given that $\displaystyle Y = y$ is Poisson with mean $\displaystyle y$. That is $\displaystyle P \{X = i| Y = y \} = e^{-y}y^{i}/i!, \ i \geq 0$. Show that the conditional distribution of $\displaystyle Y$ given that $\displaystyle X = i$ is the gamma distribution with parameters $\displaystyle (s+i, \alpha + 1)$.

So the problem is to find $\displaystyle P \{Y = y | X = i \}$ and show that it is the gamma distribution. Now $\displaystyle P \{Y =y |X =i \} = \frac{P \{Y =y, \ X = i \}}{P \{X = i\}}$. So I am guessing that the $\displaystyle \frac{1}{P \{Y = y \}}$ and the $\displaystyle \frac{1}{P \{X = i \}}$ are the factors that affect whether the distribution is Poisson or Gamma.

PS: Is R the best stats software in general? Is Jmp good?
• Jan 19th 2008, 11:44 PM
Peritus
using Baye's theorem we get:

$\displaystyle P\{ Y = y|X = i\} = \frac{{P\{ X = i|Y = y\} f_y (y)}}{{\int\limits_0^\infty {P\{ X = i|Y = y\} f_y (y)dy} }}$

$\displaystyle P\{ Y = y|X = i\} = \frac{{Ce^{ - (\alpha + 1)y} \frac{{y^{s + i - 1} }}{{i!}}}}{{C\int\limits_0^\infty {e^{ - (\alpha + 1)y} \frac{{y^{s + i - 1} }}{{i!}}dy} }} = \frac{{e^{ - (\alpha + 1)y} y^{s + i - 1} }}{{\int\limits_0^\infty {e^{ - (\alpha + 1)y} y^{s + i - 1} dy} }} =$

$\displaystyle = \frac{{e^{ - (\alpha + 1)y} y^{s + i - 1} }}{{\frac{{(s + i - 1)!}}{{(\alpha + 1)^{s + i} }}}} = \frac{{(\alpha + 1)^{s + i} }}{{(s + i - 1)!}}e^{ - (\alpha + 1)y} y^{s + i - 1}$

which is exactly the gamma distribution with the parameters $\displaystyle (s + i,\alpha + 1)$
• Jan 20th 2008, 12:04 AM
shilz222
Ah I knew it. Whenever you are given $\displaystyle P(A|B)$ and you want to find $\displaystyle P(B|A)$ just write it as $\displaystyle P(B|A) = \frac{P(B)P(A|B)}{P(A)}$.