# conditional binomial is a poisson distribution

#### exuberant

##### New Member
Hi, I'm fighting with this problem for a while. There is something important I'm missing

So the problem goes like this X~Poisson(lambda) and Y|X=k ~ Bi(k,p).

Prove Y~Poisson(lambda*p)

I already got to show that if Y~Poisson(mu) then X|X+Y=k ~ Bi(k, lamda/(lambda+mu))

So I to start the problem I thought

P(Y=y)=sum( P(Y=y|X=k)*P(X=k)) for k>=0

Eventually I get something like this

P(Y=y)= (p/1-p)^y * e^(-lamda)/y! * sum ( (lamda-p)^k / (k-n)!)

I tried to move on and I can't. After long while trying I thought of solving the problem through moment generator functions. But I'm very lost because I got a some of multpilications, is it true that Mt(Y) = sum(Mt(Y|X=k)*Mt(X) ?

Thanks for reading and any hint

#### BGM

##### TS Contributor
I think directly attacking the pmf is not hard also:

Given $$X \sim \mathrm{Poisson}(\lambda), Y|X = k \sim \mathrm{Binomial}(k, p)$$

$$\Pr\{X = k\} = e^{-\lambda}\frac {\lambda^k} {k!}, k = 0, 1, 2, ..$$

$$\Pr\{Y = y|X = k\} = {k \choose y} p^y (1 - p)^{k - y}, y = 0, 1, 2, ..., k$$

For $$y = 0, 1, 2, ...$$

$$\Pr\{Y = y\} = \sum_{k=y}^{+\infty} \Pr\{Y = y|X = k\}\Pr\{X = k\}$$

$$= \sum_{k=y}^{+\infty} {k \choose y} p^y (1 - p)^{k - y} e^{-\lambda} \frac {\lambda^k} {k!}$$

$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} \sum_{k=y}^{+\infty} \frac {[\lambda (1 - p)]^{k-y}} {(k - y)!}$$

$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} \sum_{k=0}^{+\infty} \frac {[\lambda (1 - p)]^{k}} {k!}$$

$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} e^{\lambda(1 - p)}$$

$$= e^{-\lambda p} \frac {(\lambda p)^y} {y!}$$

$$\Rightarrow Y \sim \mathrm{Poisson}(\lambda p)$$

#### exuberant

##### New Member
Thanks a lot.

I was trying to do that but without adding the lambda^y * lambda^-y I couldn't get anywhere. I even knew I had to put a lambda^y, but I couldn't find how

I guess having the k-y! should have been a hint.

It seems very clear now, thanks again.

#### Cierra

##### New Member
Hi,
I am struggling with this same problem setup: X~ Poi(λ),Y|X=k ~Bin(k,p)

But I need to show:
(a) Using the moment generating functions show that Y has a Poi(λp) distribution.
(b) Show that Y and X-Y are independent and find the conditional distribution of X given Y=y

I have solved part (a) using mgfs as it directed. I will show my solution since this approach was mentioned above with no solution:

E(e^tY )=E[E(e^tY│X=k) ]
= E[(pe^t+(1-p) )^k ]
= ∑〖(pe^t+(1-p) )^k P(X=k) 〗
=∑〖(pe^t+(1-p) )^k e^(-λ) λ^k/k!〗
=∑〖(λpe^t+λ(1-p) )^k e^(-λ)/k!〗
= e^(-λ) ∑(λpe^t+λ(1-p) )^k/k!
= e^(-λ) e^(λpe^t+λ(1-p) )
= e^(λpe^t-λp)=e^(λp(e^t-1))

Which is the mgf for the Poi(λp) distribution.

(where the summation is from k=0 to ∞ in each line involving a summation above- Sorry, I am not familiar with how to post equations.)

Part (b) is where I have run into trouble. I have shown (hopefully correctly) that X-Y~Bin(k,1-p):

P[X-Y=u]
=P[Y=k-u|X=k]
= kC(k-u) p^(k-u) 〖(1-p)〗^u
= kCu 〖(1-p)〗^u p^(k-u)

Which is the pgf of the Bin(k, 1-p) distribution.

I have tried unsuccessfully to show that X and X-Y are independent.

I have also tried unsuccessfully to find the conditional distribution of X|Y=y.

I think I’m missing something important because I fail to see the need to any relationship between the independence of X and X-Y and the conditional distribution of X|Y=y while the wording of the problem suggests that these two are somehow related…

Any help/hints/tips/etc. would be greatly appreciated.

#### BGM

##### TS Contributor
For $$u = 0, 1, 2, ...$$,

$$\Pr\{X - Y = u\} = \sum_{k=u}^{+\infty} \Pr\{X - Y = u|X = k\}\Pr\{X = k\}$$

$$=\sum_{k=u}^{+\infty} \Pr\{Y = k - u|X = k\}\Pr\{X = k\}$$

$$=\sum_{k=u}^{+\infty} {k \choose k - u}p^{k-u}(1 - p)^u e^{-\lambda} \frac {\lambda^k} {k!}$$

$$= e^{-\lambda} \frac {[\lambda(1 - p)]^u} {u!} \sum_{k=u}^{+\infty} \frac {(\lambda p)^{k-u}} {(k -u)!}$$

$$= e^{-\lambda} \frac {[\lambda(1 - p)]^u} {u!} \sum_{k=0}^{+\infty} \frac {(\lambda p)^k} {k!}$$

$$= e^{-\lambda} \frac {[\lambda(1 - p)]^u} {u!} e^{\lambda p} = e^{-\lambda(1 - p)} \frac {[\lambda(1 - p)]^u} {u!}$$

$$\Rightarrow X - Y \sim \mathrm{Poisson}(\lambda(1 - p))$$

Then consider

$$\Pr\{Y = y, X - Y = u\} = \Pr\{Y = y, X - Y = u|X = u + y\}\Pr\{X = u + y\}$$

$$= \Pr\{Y = y|X = u + y\}\Pr\{X = u + y\}$$

$$= {u + y \choose y } p^y (1-p)^u e^{-\lambda} \frac {\lambda^{u+y}} {(u+y)!}$$

$$= e^{-\lambda p} \frac {(\lambda p)^y} {y!} e^{-\lambda(1 - p)} \frac {[\lambda (1-p)]^u} {u!}$$

$$= \Pr\{Y = y\}\Pr\{X - Y = u\} ~~ \forall u, y$$

$$\Rightarrow Y, X - Y$$ are independent.

Finally, $$\Pr\{X = k|Y = y\} = \Pr\{X - y = k - y|Y = y\} = \Pr\{X - Y = k - y|Y = y\}$$

$$= \Pr\{X - Y = k - y\} = e^{-\lambda(1 - p)} \frac {[\lambda(1 - p)]^{k - y}} {(k-y)!}, k = y, y+1, y+2, ...$$

which is a Poisson distribution shifted by $$y$$

#### Cierra

##### New Member
Thank you so much BGM! That was such a silly mistake that I was making in finding the distribution of X-Y. Once I have the correct distribution for X-Y showing Y and X-Y are independent is simple. That is a nice trick for finding the conditional distribution. I'm not sure I would have thought of that. Thanks for your help!

#### saubersbox

##### New Member
Then consider

$$\Pr\{Y = y, X - Y = u\} = \Pr\{Y = y, X - Y = u|X = u + y\}\Pr\{X = u + y\}$$
$$\Pr\{Y = y, X - Y = u\} =\sum_{u+y=0}^{+\infty} \Pr\{Y = y, X - Y = u|X = u + y\}\Pr\{X = u + y\}$$

#### BGM

##### TS Contributor
Yes that is my silly mistake. It should be

$$\Pr\{Y = y, X - Y = u\} = \Pr\{Y = y, X = u + y\}$$

#### kestertan

##### New Member
I think directly attacking the pmf is not hard also:

Given $$X \sim \mathrm{Poisson}(\lambda), Y|X = k \sim \mathrm{Binomial}(k, p)$$

$$\Pr\{X = k\} = e^{-\lambda}\frac {\lambda^k} {k!}, k = 0, 1, 2, ..$$

$$\Pr\{Y = y|X = k\} = {k \choose y} p^y (1 - p)^{k - y}, y = 0, 1, 2, ..., k$$

For $$y = 0, 1, 2, ...$$

$$\Pr\{Y = y\} = \sum_{k=y}^{+\infty} \Pr\{Y = y|X = k\}\Pr\{X = k\}$$

$$= \sum_{k=y}^{+\infty} {k \choose y} p^y (1 - p)^{k - y} e^{-\lambda} \frac {\lambda^k} {k!}$$

$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} \sum_{k=y}^{+\infty} \frac {[\lambda (1 - p)]^{k-y}} {(k - y)!}$$

$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} \sum_{k=0}^{+\infty} \frac {[\lambda (1 - p)]^{k}} {k!}$$

$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} e^{\lambda(1 - p)}$$

$$= e^{-\lambda p} \frac {(\lambda p)^y} {y!}$$

$$\Rightarrow Y \sim \mathrm{Poisson}(\lambda p)$$
hi, with reference to the above posted equation, how did u get from:
$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} \sum_{k=y}^{+\infty} \frac {[\lambda (1 - p)]^{k-y}} {(k - y)!}$$
to
$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} \sum_{k=0}^{+\infty} \frac {[\lambda (1 - p)]^{k}} {k!}$$

#### Dason

hi, with reference to the above posted equation, how did u get from:
$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} \sum_{k=y}^{+\infty} \frac {[\lambda (1 - p)]^{k-y}} {(k - y)!}$$
to
$$= e^{-\lambda} \frac {(\lambda p)^y} {y!} \sum_{k=0}^{+\infty} \frac {[\lambda (1 - p)]^{k}} {k!}$$
Instead of indexing by k what happens if you index using something like j = k-y?

#### kestertan

##### New Member
Instead of indexing by k what happens if you index using something like j = k-y?
oh so are we able to just index the number to just j = k-y? are there any conditions in order to be able to index the number as such?
sorry for immediately understanding it, im quite new to probability.

#### kestertan

##### New Member
**
oh so are we able to just index the number to just j = k-y? are there any conditions in order to be able to index the number as such?
sorry for not immediately understanding it, im quite new to probability.
sorry made a typo in the previous message thanks for replying btw

#### kestertan

##### New Member
**

sorry made a typo in the previous message thanks for replying btw
ok i have figured that out, using euler formula to solve the equation thanks for all the help!

#### belaystat

##### New Member
Hello all

What will happen if X takes 0

For $$u = 0, 1, 2, ...$$,

$$\Pr\{X - Y = u\} = \sum_{k=u}^{+\infty} \Pr\{X - Y = u|X = k\}\Pr\{X = k\}$$

$$=\sum_{k=u}^{+\infty} \Pr\{Y = k - u|X = k\}\Pr\{X = k\}$$

$$=\sum_{k=u}^{+\infty} {k \choose k - u}p^{k-u}(1 - p)^u e^{-\lambda} \frac {\lambda^k} {k!}$$

$$= e^{-\lambda} \frac {[\lambda(1 - p)]^u} {u!} \sum_{k=u}^{+\infty} \frac {(\lambda p)^{k-u}} {(k -u)!}$$

$$= e^{-\lambda} \frac {[\lambda(1 - p)]^u} {u!} \sum_{k=0}^{+\infty} \frac {(\lambda p)^k} {k!}$$

$$= e^{-\lambda} \frac {[\lambda(1 - p)]^u} {u!} e^{\lambda p} = e^{-\lambda(1 - p)} \frac {[\lambda(1 - p)]^u} {u!}$$

$$\Rightarrow X - Y \sim \mathrm{Poisson}(\lambda(1 - p))$$

Then consider

$$\Pr\{Y = y, X - Y = u\} = \Pr\{Y = y, X - Y = u|X = u + y\}\Pr\{X = u + y\}$$

$$= \Pr\{Y = y|X = u + y\}\Pr\{X = u + y\}$$

$$= {u + y \choose y } p^y (1-p)^u e^{-\lambda} \frac {\lambda^{u+y}} {(u+y)!}$$

$$= e^{-\lambda p} \frac {(\lambda p)^y} {y!} e^{-\lambda(1 - p)} \frac {[\lambda (1-p)]^u} {u!}$$

$$= \Pr\{Y = y\}\Pr\{X - Y = u\} ~~ \forall u, y$$

$$\Rightarrow Y, X - Y$$ are independent.

Finally, $$\Pr\{X = k|Y = y\} = \Pr\{X - y = k - y|Y = y\} = \Pr\{X - Y = k - y|Y = y\}$$

$$= \Pr\{X - Y = k - y\} = e^{-\lambda(1 - p)} \frac {[\lambda(1 - p)]^{k - y}} {(k-y)!}, k = y, y+1, y+2, ...$$

which is a Poisson distribution shifted by $$y$$