Find variance of binomial distribution Y in terms of the number of trials

1k Views Asked by At

The random variable $Y$ has a binomial distribution with n trials and success probability $X$ where n is a given constant and $X$ is a uniform($0,1$) random variable. What is $Var(Y)$ in terms of n?

$X\sim U(0,1)$

$Y\sim B(n,X)$

$Var(Y) = E(Y^2) - E(Y)^2$

I know that $E(Y) = E(nX) = n\times E(X) = \frac{1}{2}n$

But how do I find $E(Y^2)$?

3

There are 3 best solutions below

0
On BEST ANSWER

$Var(Y) = Var(E[Y|X]) + E[Var(Y|X)]$

$ = Var(nX) + E[nX(1−X)]$

$ = Var(nX) + E[nX]−E[nX^2]$

$ = n^2Var(X)+nE[X]−nE[X^2]$

$ = \frac{n^2}{12} + \frac{n}{2}−\frac{n}{3}$

$ =\frac{n^2}{12} + \frac{n}{6}$

6
On

Hint: You can use the Law of total variance.

$Var(Y)=\mathbb E(Var(Y| U))+{Var}( \mathbb E(Y| U))$

$=\mathbb E(nU-nU^2)+Var(nU) $

2
On

If $Z$ has binomial distribution with parameters $n$ and $p$ then: $$\mathbb EZ^2=\mathsf{Var}Z+(\mathbb EZ)^2=np(1-p)+ n^2p^2$$

That means that here $$\mathbb E[Y^2\mid X]= nX(1-X)+n^2X^2$$

Now apply that: $$\mathbb EY^2=\mathbb E[\mathbb EY^2\mid X]$$

You can also go for $\mathsf{Var}Y$ immediately.

For that see the answer of callculus.