Independence as a Loglinear Model
A two-way table records counts classified by a row variable and a column variable. The independence model says that the expected count pattern has no special row-column pairing: row and column effects combine additively on the log-mean scale. This does not require the row or column effects to be absent. It requires the cell mean to be built from those effects without an additional term specific to a row-column combination.
Let \(Y_{ij}\) be the count in row \(i\) and column \(j\), for \(i=1,\ldots,I\) and \(j=1,\ldots,J\). In the Poisson loglinear formulation, the cell counts are independent Poisson random variables with means \(\mu_{ij}>0\). A convenient reference-cell parameterization of the independence model is:
Here \(\lambda\) is the log mean in the reference cell, while \(\alpha_i\) and \(\beta_j\) describe row and column effects relative to the first row and column. The constraints set the reference effects to zero; they do not change the model’s fitted means.
To see the multiplicative form, exponentiate the additive specification:
where \(a_i=\exp(\lambda+\alpha_i)\) and \(b_j=\exp(\beta_j)\), for example. A row effect multiplies the means throughout its row; a column effect multiplies the means throughout its column. Independence is the absence of any further cell-specific adjustment.
What the Model Says About the Table
A positive mean array has this multiplicative form precisely when every pair of rows and columns satisfies the same cross-product relation:
This relation says that comparing two columns gives the same mean ratio in every row. It is one way to check the absence of interaction without relying on a particular choice of reference categories.
Proof. If \(\mu_{ij}=a_i b_j\), then \(\mu_{ij}\mu_{k\ell}=a_i b_j a_k b_\ell=a_i b_\ell a_k b_j=\mu_{i\ell}\mu_{kj}\). Conversely, suppose all the cross-product equalities hold. Fix reference indices \(1,1\). Taking \(k=1,\ell=1\) gives \(\mu_{ij}\mu_{11}=\mu_{i1}\mu_{1j}\), so \(\mu_{ij}=(\mu_{i1}/\mu_{11})\mu_{1j}\). This is a row factor times a column factor. Taking logarithms of positive factors gives an additive row-plus-column form. Thus all three conditions are equivalent. \(\square\)
The mean structure also describes independence of the classifications. Let \(p_{ij}=\mu_{ij}/\mu_{++}\), where \(\mu_{++}=\sum_i\sum_j\mu_{ij}\). Under the multiplicative form, the cell probabilities factor into a row probability and a column probability:
Thus, conditional on the grand total in the independent-Poisson sampling formulation, the row and column classifications of a count are independent. This is the substantive row-column independence represented by the model. It is not the same claim as independence of the Poisson cell counts: under the usual Poisson sampling formulation, the cell counts are specified to be independent across cells whether or not their means satisfy the independence model.
Worked Example: Checking a Mean Array for Independence
Suppose a \(2\times 3\) table has proposed means \(\begin{pmatrix}2&4&8\\3&6&12\end{pmatrix}\). Determine whether these means satisfy the independence model.
The first row is \(2(1,2,4)\), and the second is \(3(1,2,4)\). Therefore \(\mu_{ij}=a_i b_j\) with row factors \(a_1=2,a_2=3\) and column factors \(b_1=1,b_2=2,b_3=4\). Taking logs gives the required additive structure.
As a direct check, the ratio of the second row mean to the first is \(3/2\) in every column: \(3/2=6/4=12/8\). For the first and third columns, the cross-products agree: \(2(12)=8(3)=24\). The row and column effects may be substantial; independence does not mean that all six means are equal.
Fitted Means and Observed Margins
Write \(y_{i+}=\sum_j y_{ij}\) and \(y_{+j}=\sum_i y_{ij}\) for the observed row and column totals. The independence model has a useful maximum-likelihood property: when a finite interior maximum-likelihood estimate exists, its fitted means \(\hat\mu_{ij}\) reproduce these margins. This is a statement about fitted totals, not about matching each observed cell.
The reason follows from the score equations. Under independent Poisson sampling, omitting terms that do not depend on the parameters, the log-likelihood is \(\ell=\sum_{i,j}(y_{ij}\log\mu_{ij}-\mu_{ij})\). In the reference-cell parameterization, differentiating with respect to the intercept and each non-reference row and column effect gives:
Proof. At an interior maximum, the displayed derivatives are zero. The intercept equation gives equality of the fitted and observed grand totals. Each non-reference row score equation gives \(\sum_j\hat\mu_{ij}=y_{i+}\) for \(i>1\). Subtracting these row totals from the grand-total equality yields the same equality for row 1. Each non-reference column score equation gives \(\sum_i\hat\mu_{ij}=y_{+j}\) for \(j>1\); subtracting those column totals from the grand-total equality gives the equality for column 1. Hence all fitted row and column margins equal their observed counterparts. The log-likelihood is concave in the loglinear parameters: its Hessian is the negative of a sum of terms \(\mu_{ij}x_{ij}x_{ij}^{T}\), where \(x_{ij}\) is the parameter-design vector for cell \((i,j)\). Therefore a stationary point is a maximum. The stated margin identities hold at any such interior maximum. \(\square\)
The qualification matters. If the data have zero margins or other features that prevent a finite interior estimate, a maximum may lie on the boundary rather than at finite parameter values. The score equations above apply at a finite interior maximum; they should not be used to claim finite estimates in every possible table.
Worked Example: Reading the Margin-Matching Property
Suppose the observed table is \(\begin{pmatrix}1&4&9\\4&6&11\end{pmatrix}\), and consider the fitted mean array \(\begin{pmatrix}2&4&8\\3&6&12\end{pmatrix}\) from the earlier calculation. Check the margins and explain what they establish.
The observed row totals are \(1+4+9=14\) and \(4+6+11=21\). The observed column totals are \(1+4=5\), \(4+6=10\), and \(9+11=20\).
For the proposed fitted means, the row totals are \(2+4+8=14\) and \(3+6+12=21\); the column totals are \(2+3=5\), \(4+6=10\), and \(8+12=20\). Every fitted margin matches its observed counterpart. Since the proposed means also satisfy the independence model, these score equations are satisfied. The log-likelihood concavity described above shows that this is a maximum-likelihood fit.
The cells need not match: for example, the observed first cell is 1 while its fitted mean is 2. Margin matching is therefore not a claim that the independence model reproduces the observed table cell by cell.
Worked Example: Interpreting the Implied Row and Column Distributions
For the fitted means \(\begin{pmatrix}2&4&8\\3&6&12\end{pmatrix}\), find the implied row and column proportions and verify independence for one cell.
The grand total of the means is \(2+4+8+3+6+12=35\). The row totals are 14 and 21, so the row proportions are \(14/35=0.4\) and \(21/35=0.6\). The column totals are 5, 10, and 20, giving column proportions \(5/35=1/7\), \(10/35=2/7\), and \(20/35=4/7\).
The probability assigned to the first-row, third-column cell is \(8/35\). Under independence the product of its row and column proportions is \(0.4(4/7)=(2/5)(4/7)=8/35\), exactly the same value. The same factorization applies to each cell because the means are products of row and column factors.
Common Mistakes and Practical Meaning
- Confusing no interaction with no effects. The independence model permits row and column effects. It excludes only an extra row-column term. Equal means throughout the table would be a much stronger restriction.
- Equating independent Poisson counts with row-column independence. Independence of the random cell counts is part of the usual Poisson sampling setup. Row-column independence is a separate restriction on how their means combine.
- Expecting every fitted cell to equal its observed count. The maximum-likelihood fit under independence matches row and column margins, not necessarily individual cells.
- Treating a reference-cell constraint as a scientific assumption. Setting \(\alpha_1=\beta_1=0\) chooses a parameterization. It does not assert that the first row and column have no meaningful effect.
The no-interaction specification is useful because it translates a substantive claim—no association between two classifications—into a compact model for expected counts. Its multiplicative form gives a clear interpretation of the fitted mean pattern, while margin matching explains which summaries the maximum-likelihood fit preserves. Whether the restriction describes the data adequately is a separate question from writing and interpreting the model.
Check Your Understanding
Use the definitions and results above to answer these questions.
- Write the reference-cell loglinear independence model for an \(I\times J\) table and state the parameter constraints.
- Explain why an additive row-plus-column model on the log-mean scale becomes multiplicative on the mean scale.
- For positive means, what cross-product equality characterizes the absence of a row-column interaction?
- State the margin-matching property of a finite interior maximum-likelihood fit. Does it require fitted and observed cell counts to agree?
- Why does independence of Poisson cell counts, by itself, not establish row-column independence?