# Conditional Variance & Predictions: 7 Important Facts

In this article the conditional Variance and predictions using conditional expectation for the different kind of random variable with some examples we will discuss.

## Conditional Variance

The conditional variance of random variable X given Y is defined in similar way as conditional Expectation of random variable X given Y as

(X|Y)=E[(X-E[X|Y])2|Y]

here variance is the conditional expectation of difference between random variable and square of conditional expectation of X given Y when the value of Y is given.

The relation between the conditional variance and conditional expectation is

(X|Y) = E[X2|Y] – (E[X|Y])2

E[(X|Y)] = E[E[X2|Y]] – E[(E[X|Y])2]

= E[X2] – E[(E[X\Y])2]

since E[E[X|Y]] = E[X], we have

(E[X|Y]) = E[(E[X|Y])2] – (E[X])2

this is somehow similar from the relation of unconditional variance and expectation which was

Var(X) = E[X2] – (E[X])2

and we can find the variance with the help of conditional variance as

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

## Example of conditional variance

Find the mean and variance of the number of travelers who enters into the bus if the people arrived at bus depot is Poisson distributed with mean λt and the initial bus arrived at bus depot is uniformly distributed over the interval (0,T) independent of people arrived or not.

Solution:

To find the mean and variance let for any time t , Y is the random variable for the time bus arrive and N(t) is the number of arrivals

E[N(Y)|Y = t] = E[N(t)|Y = t]

by the independence of Y and N(t)

=λt

since N(t) is Poisson with mean \lambda t
Hence

E[N(Y)|Y]=λY

so taking expectations gives

E[N(Y)] = λE[Y] = λT/2

To obtain Var(N(Y)), we use the conditional variance formula

thus

(N(Y)|Y) = λY

E[N(Y)|Y] = λY

Hence, from the conditional variance formula,

Var(N(Y)) = E[λY]+(λY)

=λT/2 + λ2T2/12

where we have used the fact that Var(Y)=T2 / 12.

## Variance of a sum of a random number of random variables

consider the sequence of independent and identically distributed random variables X1,X2,X3,………. and another random variable N independent of this sequence, we will find variance of sum of this sequence as

using

which is obvious with the definition of variance and conditional variance for the individual random variable to the sum of sequence of random variables hence

## Prediction

In prediction the value of one random variable can be predicted on the basis of observation of another random variable, for prediction of random variable Y if observed random variable is X we use g(X) as the function which tells the predicted value, obviously we try to choose g(X) closed to Y for this the best g is g(X)=E(Y|X) for this we must have to minimize the value of g by using the inequality

This inequality we can get as

However, given X, E[Y|X]-g(X), being a function of X, can be treated as a constant. Thus,

which gives the required inequality

## Examples on Prediction

1. It is observed that the height of a person is six feet, what would be the prediction of his sons height after grown up if the height of son which is x inches now is normally distributed with mean x+1 and variance 4.

Solution: let X be the random variable denoting the height of the person and Y be the random variable for the height of son, then the random variable Y is

Y=X+e+1

here e represent the normal random variable independent of random variable X with mean zero and variance four.

so the prediction for the sons height is

so the height of the son will be 73 inches after growth.

2. Consider an example of sending signals from location A and location B, if from location A a signal value s is sent which at location B received by normal distribution with mean s and variance 1 while if the signal S sent at A is normally distributed with mean \mu and variance \sigma^2, how we can predict that the signal value R sent from location A will be received is r at location B?

Solution: The signal values S and R denote here the random variables distributed normally, first we find the conditional density function S given R as

this K is independent of S, now

here also C1 and C2 are independent on S, so the value of conditional density function is

C is also independent on s, Thus the signal sent from location A as R and received at location B as r is normal with mean and variance

and the mean square error for this situation is

## Linear Predictor

Every time we can not find the joint probability density function even the mean, variance and the correlation between two random variables is known, in such a situation linear predictor of one random variable with respect to another random variable is very helpful which can predict the minimum, so the for the linear predictor of random variable Y with respect to random variable X we take a and b to minimize

Now differentiate partially with respect to a and b we will get

solving these two equations for a nd b we will get

thus minimizing this expectation gives the linear predictor as

where the means are the respective means of random variables X and Y, the error for the linear predictor will be obtained with the expectation of

This error will be nearer to zero if correlation is perfectly positive or perfectly negative that is coefficient of correlation is either +1 or -1.

## Conclusion

The conditional variance for the discrete and continuous random variable with different examples were discussed, one of the important application of conditional expectation in prediction is also explained with suitable examples and with best linear predictor, if you require further reading go through below links.

For more post on Mathematics, please refer to our Mathematics Page

A first course in probability by Sheldon Ross

Schaum’s Outlines of Probability and Statistics

An introduction to probability and statistics by ROHATGI and SALEH

Scroll to Top