# Thread: X and Y are indicator variables

1. ## X and Y are indicator variables

Question : X and Y are indicator variables for whether or not the events A and B occur, i.e.

$\displaystyle X = \begin{cases} 1 & if \ A \ occur \\ 0 & otherwise \end{cases}$

$\displaystyle Y = \begin{cases} 1 & if \ B \ occur \\ 0 & otherwise \end{cases}$

Compute cov(X,Y) If cov(X,Y)>0, show that P(Y=1|X=1)> P(Y=1)

---------------------------------------------------------------

$\displaystyle cov(X,Y) = E[(X- \mu_x)(Y - \mu_y)]$......for cov(X,Y)>0 and others

2. Hello,

use this formula of the covariance :

cov(X,Y)=E[XY]-E[X]E[Y]

as for computing E[XY], think that XY=1 or 0, and find its probability in each case.

3. Pr(X occuring) = $\displaystyle \frac{1}{2}$ (similar for Pr(Y))

now
E[X] = $\displaystyle \sum x Pr(X)$ = 0.5 similarly E[Y] = 0.5

E[X,Y] = $\displaystyle \sum \sum$ x . y . Pr(X,Y) = 1.0(0.5) + 0.1(0.5) + 1.1(1)............Is this correct ????

4. Hey, it's E[XY] (a product), not E[X,Y]

$\displaystyle E[XY]=\sum_{j=0}^1\sum_{k=0}^1 jkP(X=j,Y=k)=1\cdot 0 P(X=1,Y=0)+1\cdot 0 P(X=0,Y=1)$ $\displaystyle +0\cdot 0 P(X=0,Y=0)+1\cdot 1 P(X=1,Y=1) =P(X=1,Y=1)=P(A\cap B)$

Or you could've seen it this way : XY = 0 or 1, according to the values of X and Y. So it follows a Bernoulli distribution, with parameter P(XY=1)=P(X=1,Y=1)

Plus, X is not an event, so we don't talk about "X occurring". Rather "A occurring". And nothing tells you that the probability is 1/2 !!! You have to keep them in formal form.

5. $\displaystyle \therefore P(X=1,Y=1) = \frac{1}{2}$

6. Originally Posted by zorro
$\displaystyle \therefore P(X=1,Y=1) = \frac{1}{2}$
No !!!

It's a constant you don't know. It's not necessarily 1/2 !