Why Check the Whole Joint Law?
For discrete random variables, independence can be checked directly from their probability mass functions. The key comparison is between the joint probability at each pair of values and the product of the corresponding marginal probabilities. A match at one pair is not enough: independence is a property of the entire joint law.
This cell-by-cell approach is especially useful for finite probability tables. It also makes structural zeros informative. If each variable can take a value with positive probability, independence requires positive joint probability at every pair formed from such values.
Marginals and the Discrete Factorization Criterion
For discrete variables, that event-based definition has a simple equivalent form: it is enough to compare the joint and marginal masses at every pair of values. In a finite table, first sum each row and column to find the marginals; then compare every entry with the product of its row and column marginal probabilities.
Proof. Suppose first that \(X\) and \(Y\) are independent. Take the sets \(A=\{x\}\) and \(B=\{y\}\) in the definition. Then $$ p_{X,Y}(x,y)=P(X=x,Y=y)=P(X=x)P(Y=y)=p_X(x)p_Y(y). $$ Thus the factorization holds at every pair.
Conversely, suppose the factorization holds at every pair. For any sets \(A\) and \(B\) of possible values, the events can be written as disjoint unions of singleton events. Therefore, using nonnegative sums, $$ \begin{aligned} P(X\in A,Y\in B) &=\sum_{x\in A}\sum_{y\in B}p_{X,Y}(x,y)\\ &=\sum_{x\in A}\sum_{y\in B}p_X(x)p_Y(y)\\ &=\left(\sum_{x\in A}p_X(x)\right)\left(\sum_{y\in B}p_Y(y)\right)\\ &=P(X\in A)P(Y\in B). \end{aligned} $$ The product identity for nonnegative sums holds for finite or countable sets of values, including infinite ones. Hence \(X\) and \(Y\) are independent. \(\square\)
A Systematic Table Check
For a finite joint PMF, independence is a direct calculation rather than a judgment about whether the table “looks random.” A reliable workflow is:
Sum across each row to obtain \(p_X(x)\), and down each column to obtain \(p_Y(y)\), according to the table’s layout.
For each cell \((x,y)\), calculate \(p_X(x)p_Y(y)\).
The law is independent exactly when each product equals the joint mass in that cell. One mismatch is enough to establish dependence.
Worked Example: Verifying an Independent Joint PMF
Suppose \(X\) takes values \(0,1\), and \(Y\) takes values \(a,b\), with joint PMF given below. Determine whether \(X\) and \(Y\) are independent.
| \(Y=a\) | \(Y=b\) | Row sum | |
|---|---|---|---|
| \(X=0\) | 0.10 | 0.30 | 0.40 |
| \(X=1\) | 0.15 | 0.45 | 0.60 |
| Column sum | 0.25 | 0.75 | 1.00 |
The row sums give \(p_X(0)=0.40\) and \(p_X(1)=0.60\). The column sums give \(p_Y(a)=0.25\) and \(p_Y(b)=0.75\). Check all four products:
Each product matches the joint mass in its cell, so the factorization criterion holds everywhere. Therefore \(X\) and \(Y\) are independent. As a check on the table itself, its four joint masses sum to \(0.10+0.30+0.15+0.45=1.00\).
Why Selected Cells Can Mislead
A common mistake is to check a convenient cell—or even several cells—and conclude that the variables are independent when those entries factor. The criterion requires equality at every pair of values. The next table has uniform marginal distributions, and one cell factors exactly, but another does not.
Worked Example: One Factoring Cell Does Not Establish Independence
Let \(X,Y\) each take values \(1,2,3\), with the following joint PMF.
| \(Y=1\) | \(Y=2\) | \(Y=3\) | Row sum | |
|---|---|---|---|---|
| \(X=1\) | \(1/6\) | \(1/18\) | \(1/9\) | \(1/3\) |
| \(X=2\) | \(1/18\) | \(1/6\) | \(1/9\) | \(1/3\) |
| \(X=3\) | \(1/9\) | \(1/9\) | \(1/9\) | \(1/3\) |
| Column sum | \(1/3\) | \(1/3\) | \(1/3\) | 1 |
The table is a valid PMF: all entries are nonnegative, and its row sums give total probability \(3(1/3)=1\). Every row and column marginal is \(1/3\). At the cell \((3,3)\), factorization holds: $$ p_{X,Y}(3,3)=\frac{1}{9} =\left(\frac{1}{3}\right)\left(\frac{1}{3}\right) =p_X(3)p_Y(3). $$ But at \((1,1)\), $$ p_{X,Y}(1,1)=\frac{1}{6} \ne \frac{1}{9} =\left(\frac{1}{3}\right)\left(\frac{1}{3}\right) =p_X(1)p_Y(1). $$ One failed equality proves that \(X\) and \(Y\) are dependent. The factoring cell was real, but it was not evidence that the whole table factors.
Structural Zeros and the Support Pattern
A cell with joint probability zero deserves particular attention. If both marginal probabilities at that cell’s values are positive, their product is positive, so the factorization criterion fails immediately. This gives a useful support test before doing a full table comparison.
Proof. Under independence, \(p_{X,Y}(x,y)=p_X(x)p_Y(y)\). A product of two nonnegative numbers is positive exactly when both factors are positive. This proves the stated equivalence. \(\square\)
The support condition is a quick way to disprove independence, not a complete way to establish it. A table can have positive mass at every pair of marginal-positive values but still fail to factor numerically, as the preceding example demonstrates.
Worked Example: A Missing Pair Rules Out Independence
Suppose the only pairs with positive joint mass are \((0,0)\), \((0,1)\), and \((1,0)\), each with probability \(1/3\). Find the marginals and determine whether the variables are independent.
The marginal masses are $$ p_X(0)=\frac{2}{3},\quad p_X(1)=\frac{1}{3},\qquad p_Y(0)=\frac{2}{3},\quad p_Y(1)=\frac{1}{3}. $$ Both \(X=1\) and \(Y=1\) have positive marginal probability. If \(X\) and \(Y\) were independent, their joint mass at \((1,1)\) would have to be $$ p_X(1)p_Y(1)=\left(\frac{1}{3}\right)\left(\frac{1}{3}\right)=\frac{1}{9}. $$ But the pair \((1,1)\) is absent from the joint support, so \(p_{X,Y}(1,1)=0\). Since \(0\ne 1/9\), the variables are dependent. In fact, the positive-marginal support contains all four pairs in \(\{0,1\}\times\{0,1\}\), while the joint law assigns positive mass to only three of them.
Common Mistakes and Practical Interpretation
- Checking only one cell. Equality \(p_{X,Y}(x,y)=p_X(x)p_Y(y)\) at a single pair is necessary but not sufficient. Check all pairs, or find one mismatch to disprove independence.
- Ignoring a zero cell. A zero joint mass conflicts with independence whenever both corresponding marginal masses are positive.
- Using an incomplete table. Marginal sums must include every possible value, including values with zero mass when they are displayed. Confirm that the joint masses sum to one before interpreting the factorization check.
- Confusing equal marginals with independence. Marginals describe each variable separately; they do not determine how the variables occur together. The joint PMF supplies that information.
The factorization criterion matters because it turns an abstract property of random variables into a precise calculation on their joint law. For finite discrete models, it gives a transparent diagnostic: derive the marginals, compare every cell, and treat structural zeros as immediate evidence whenever both marginal values are possible.
Check Your Understanding
Answer each question by referring to the joint and marginal probability masses.
- What calculation produces \(p_X(x)\) from a joint PMF \(p_{X,Y}(x,y)\)?
- A table has \(p_X(0)=0.4\), \(p_Y(1)=0.5\), and \(p_{X,Y}(0,1)=0.2\). Does this cell satisfy the factorization check, and does that alone establish independence?
- If \(p_X(x)>0\), \(p_Y(y)>0\), and \(p_{X,Y}(x,y)=0\), what conclusion follows?
- Why do all pairs formed from positive-marginal values need positive joint mass under independence?
- State a reliable procedure for checking independence in a finite joint probability table.