Chapter 4 Independence and Conditional Statistics
4.1 Independence
Recall the statement of independent random variables Definition 2.3.1 that states two random variables are independent ifSubstituting this identify into Definition 3.2.1, gives an equivalent condition for two random variables to be independent. Specifically for any such that :
This is to say that the conditional probability density function is equal to the probability density function , and does not depend on at all. This makes sense: the information on the outcome of is irrelevant to the outcome of since both are independent.
Consider again the game played by Annie and Bertie in Example 3.2.2, the scores of which are governed by the random variables and . We saw in Example 2.3.3 that and are dependent. Verify this using the new equivalent definition for independence.
In Example 4.2.2, we calculated that the conditional PDF is given by
From Example 2.1.8:
Note the result of Example 4.1.1 could have been deduced solely from the fact that the expression for contains : without looking at explicitly we know it will contain no reference to and so cannot be equal to .
Similarly independence is equivalent to the condition that . This criteria is deduced in an analogous fashion to the above identity .
4.2 Conditional Expectation
In the Nike versus Adidas example at the opening of the chapter, two random variables were considered: and . One piece of information that we could give to Phil Knight is the expectation of . However this doesn’t take into account all the information at our disposable. We know the value that the random variable takes. The value we really want to calculate is the expectation of given the value the .
Posing this question in a general setting, motivates the following definition:
The conditional expectation of given , is defined by where either is the conditional PMF of given , or is the conditional PDF of given .
Note that this definition covers both discrete and continuous random variables.
You are seeking to buy a car, and want to estimate the cost. You find an article online that has collected data on cars listed across various sites. The article models the cost of the car by a random variable and the age of the car by a random variable . The probability of finding a car with and is governed by the joint PDF
For some fixed age of car , find the expected cost.
Mathematically the question is asking us to calculate .
In general it is enough to consider only the region on which is non-zero.

First we want to calculate . To do so, first calculate the marginal distribution :
Hence, for , the conditional probability density function is
Therefore by Definition 4.2.1 the conditional expectation of is
where the third equality follows from integration by parts.Critique the model that the article uses in Example 4.2.2.
Many of the nice properties of expectation such as linearity are inherited by conditional expectation.
Let be a real number, and be random variables. Each of the following rules pertaining to conditional expectation given hold in general
Similarly to the case of joint expectation in Definition 2.5.4, the definition of conditional expectation can extend to functions of random variables:
Let be continuous random variables, with conditional PDF . Then, for a function of , we have
Consider the random variables and from Example 4.2.2. Calculate .
In Example 4.2.2, we found
Therefore applying Theorem 4.2.4
Note that integration by parts has been used twice in the evaluation of the integral.
4.3 Conditional Variance
Considering again the opening Nike versus Adidas example, it would be sensible to provide Phil Knight with the variance of . However calculating the variance of doesn’t utilise our knowledge of the random variable. What we really want to calculate is the variance of given the value of .
Moving this idea to the general setting leads to the following definition:
The conditional variance of given , is defined by
Note that both of the expectations that appear on the right hand side of Definition 4.3.1 are conditional expectations. Calculating the conditional variance using this expression can be computationally difficult. The following proposition offers an alternative method by which to calculate conditional variance.
An equivalent definition of conditional variance is
The right hand side of Proposition 4.3.2 can be calculated using Theorem 4.2.4.
Consider again the random variables from Example 4.2.2. Calculate the conditional variance of given .
From Example 4.2.2 and Example 4.2.5, we know
Therefore by Proposition 4.3.2:
There is an interesting result linking the variance to a random variable to an expression in terms of the conditional expectations and variances of given a second random variable . This result is known as the Law of Total Variance:
Let be two random variables. Then
The Law of Total Variance states that the variance of decomposes as the sum of the expected variance of given and the variance of the expectation of given . This is a particularly powerful result that will be explored further in MATH1058: Statistical Models and Methods.