Joint Distribution, Conditional Probability, and Correlation Worked Example
This example shows the core multivariate Exam P workflow: read the joint table carefully, compute marginals and conditionals cleanly, then finish with covariance and correlation.
- Role
- Worked Example
- Level
- Core
- Time
- Reference
- Freshness
- Stable
Problem
A pair of discrete random variables has joint distribution P(X=0,Y=0)=0.18, P(X=0,Y=1)=0.32, P(X=1,Y=0)=0.12, and P(X=1,Y=1)=0.38. Find the marginal distribution of X, the conditional probability P(Y=1 | X=1), the covariance of X and Y, and the correlation coefficient.
What This Example Is Testing
This is testing whether you can keep the entire multivariate chain straight. On Exam P, the hardest part is often not the arithmetic. It is remembering which quantity comes from a row sum, which comes from a conditional renormalization, and which comes from a moment calculation.
Step-By-Step Solution
Start with the marginal distribution of X. Add across the Y values. That gives P(X=0)=0.18+0.32=0.50 and P(X=1)=0.12+0.38=0.50.
Now condition on X=1. The X=1 row totals 0.50, so P(Y=1 | X=1)=0.38/0.50=0.76.
For the covariance, compute expectations. Because X and Y are indicator-like variables here, E[X]=P(X=1)=0.50 and E[Y]=P(Y=1)=0.32+0.38=0.70. Also, E[XY]=1 x 1 x 0.38=0.38. So Cov(X,Y)=E[XY]-E[X]E[Y]=0.38-(0.50)(0.70)=0.03.
To get correlation, first compute the variances. Var(X)=0.50(0.50)=0.25 and Var(Y)=0.70(0.30)=0.21. The standard deviations are 0.50 and about 0.458. Therefore the correlation is 0.03/(0.50 x 0.458), about 0.131.
Final Answer
The marginal distribution of X is P(X=0)=0.50 and P(X=1)=0.50. The conditional probability is P(Y=1 | X=1)=0.76. The covariance is 0.03, and the correlation coefficient is about 0.131.
Common Wrong Answer
The most common wrong answer is dividing by the wrong denominator in the conditional step, usually 1 instead of the row total 0.50. Another common miss is to compute covariance and then stop without standardizing when the question asks for correlation.