# Thread: conditional probability using indicator variable

1. ## conditional probability using indicator variable

For an event A, let IA equal 1 if A occurs and let it equal 0 if A does not occur. For a random variable X, show that

E[X|A] = E[XIA]/P(A)

2. ## Re: conditional probability using indicator variable

this is trivial

try and do it yourself.

3. ## Re: conditional probability using indicator variable

is it correct to do in this way?
E(XIA)/P(A)
=[E(XIA|IA=0)P(IA=0)+E(XIA|IA=1)P(IA=1)]/P(A)
=[E(X|A)P(A)]/P(A)
=E(X|A)

4. ## Re: conditional probability using indicator variable

Yes, that is correct. You have used the formula which is known as "total probability" or "the law of iterated expectations".