Tutorials › Generalized Linear Mixed Models (GLMM) › Exchangeable Working Correlation In GEE

GLMM Versus GEE · Tutorial 132 of 698

Exchangeable Working Correlation In GEE

Learn when equal within-cluster correlations are a defensible GEE working assumption, how to specify the matrix, and how to check its implications.

Intermediate 10 min read

What You'll Learn

  • Write the exchangeable working correlation matrix for clusters of any size.
  • Derive the parameter range that makes the matrix positive definite.
  • Explain how the working correlation enters the GEE estimating equation.
  • Calculate a weighted residual contribution using an exchangeable matrix.
  • Estimate a common working correlation from standardized residual products.
  • Identify patterns that make equal within-cluster correlations implausible.

What “Exchangeable” Means in GEE

In clustered data, observations from the same person, clinic, school, or other unit may be dependent. A GEE analysis separates the marginal mean model from a working model for that dependence. The mean model describes the population-averaged response; the working correlation helps determine how observations within each cluster are weighted when estimating that model.

An exchangeable working correlation assumes that every distinct pair of observations within a cluster has the same correlation, regardless of their order, time separation, or other pair-specific features. It is also called a compound-symmetry correlation structure. “Working” is important: this is a simplifying covariance assumption used in estimation, not a claim that the dependence mechanism has been established as true.

Definition: For cluster \(i\), with \(n_i\) observations, an exchangeable working correlation matrix has ones on the diagonal and one common off-diagonal correlation \(\rho\): $$ \mathbf R_i(\rho)=(1-\rho)\mathbf I_{n_i}+\rho\mathbf 1_{n_i}\mathbf 1_{n_i}^{\mathsf T}. $$ Here \(\mathbf I_{n_i}\) is the \(n_i\)-dimensional identity matrix and \(\mathbf 1_{n_i}\) is a vector of \(n_i\) ones. Thus, for any distinct observations \(j\) and \(k\) in the same cluster, the working correlation is \(\rho\).

The parameter \(\rho\) is a working within-cluster correlation, not the significance level \(\alpha\). It does not require equal means or equal outcome variances. For example, observations at different visits may have different fitted means and variances while the working correlation matrix still assigns the same correlation to every pair.

How the Matrix Enters a GEE

Let there be \(m\) independent clusters. Write \(\mathbf Y_i\) for the \(n_i\)-vector of outcomes in cluster \(i\), and \(\boldsymbol\mu_i\) for its marginal mean vector. A typical marginal mean model is \(g(\mu_{ij})=\mathbf x_{ij}^{\mathsf T}\boldsymbol\beta\), where \(g\) is the link function and \(\boldsymbol\beta\) is the population-averaged regression parameter. Let \(\mathbf D_i=\partial\boldsymbol\mu_i/\partial\boldsymbol\beta^{\mathsf T}\). The working covariance matrix is $$ \mathbf V_i=\phi\,\mathbf A_i^{1/2}\mathbf R_i(\rho)\mathbf A_i^{1/2}, $$ where \(\mathbf A_i\) is diagonal with the marginal variance-function values for the observations in cluster \(i\), and \(\phi\) is a dispersion parameter when the model uses one. For Bernoulli outcomes, the variance is commonly specified as \(\mu_{ij}(1-\mu_{ij})\) and \(\phi=1\).

The GEE estimates \(\boldsymbol\beta\) by solving

$$ \mathbf U(\boldsymbol\beta)= \sum_{i=1}^{m}\mathbf D_i^{\mathsf T}\mathbf V_i^{-1} (\mathbf Y_i-\boldsymbol\mu_i)=\mathbf 0. $$

An exchangeable \(\mathbf R_i(\rho)\) therefore changes the weighting of the within-cluster residual vector \(\mathbf Y_i-\boldsymbol\mu_i\). If the marginal mean model is correctly specified and clusters are independent, a suitable GEE can estimate the marginal regression parameters consistently even when the working correlation is not exactly correct, under standard regularity conditions. A poor working structure can nevertheless reduce efficiency and can make model-based standard errors unreliable; robust variance estimation is commonly used for inference.

Admissible Values and a Useful Matrix Identity

The common pairwise correlation cannot be chosen arbitrarily. A correlation matrix must be positive definite for the usual GEE inverse to exist. For a cluster of size \(n_i\geq 2\), the eigenvalues of the exchangeable matrix are \(1-\rho\), repeated \(n_i-1\) times, and \(1+(n_i-1)\rho\), once. The first corresponds to directions whose entries sum to zero; the second corresponds to the direction \(\mathbf 1_{n_i}\).

1
Consider contrasts within a cluster.
If \(\mathbf v^{\mathsf T}\mathbf 1_{n_i}=0\), then \(\mathbf R_i\mathbf v=(1-\rho)\mathbf v\). Positive variance in these directions requires \(1-\rho>0\), or \(\rho<1\).
2
Consider the cluster-average direction.
Because \(\mathbf R_i\mathbf 1_{n_i}=[1+(n_i-1)\rho]\mathbf 1_{n_i}\), positive variance in this direction requires \(1+(n_i-1)\rho>0\).
3
Combine the restrictions.
For a cluster of size \(n_i\geq2\), positive definiteness requires \(-1/(n_i-1)<\rho<1\). If cluster sizes vary and one common \(\rho\) is used, it must satisfy the restriction for the largest cluster as well.

The corresponding inverse, useful for understanding the weights, is

$$ \mathbf R_i(\rho)^{-1} =\frac{1}{1-\rho}\left[ \mathbf I_{n_i} -\frac{\rho}{1+(n_i-1)\rho} \mathbf 1_{n_i}\mathbf 1_{n_i}^{\mathsf T} \right]. $$

This identity follows because the displayed matrix acts as \(1/(1-\rho)\) on every zero-sum contrast and as \(1/[1+(n_i-1)\rho]\) on \(\mathbf 1_{n_i}\), the reciprocals of the two eigenvalues above. When \(n_i=1\), there is no within-cluster pair and \(\rho\) has no effect on that cluster’s correlation matrix.

Worked Example: Specifying and Checking a Three-Observation Cluster

Suppose repeated measurements are collected at three visits per person. A proposed exchangeable working correlation is \(\rho=0.40\). The assumption assigns the same working correlation, 0.40, to visits 1 and 2, visits 1 and 3, and visits 2 and 3. The matrix is

$$ \mathbf R_i(0.40)= \begin{pmatrix} 1&0.40&0.40\\ 0.40&1&0.40\\ 0.40&0.40&1 \end{pmatrix}. $$

For \(n_i=3\), the admissible range is \(-1/2<\rho<1\), so 0.40 is allowed. The eigenvalues are \(1-0.40=0.60\), twice, and \(1+2(0.40)=1.80\), once. All are positive, confirming that this matrix is positive definite. This check establishes mathematical validity, not whether equal correlation is a plausible description of the data.

If measurements close in time are expected to be more alike than measurements far apart, the equal-correlation assumption may be questionable. The matrix itself makes no distinction between those pairs: it has no information about visit order or time gaps.

What the Working Weights Do

With equal marginal variances, the exchangeable inverse has a particularly clear interpretation. It changes the weight assigned to the cluster-average residual direction differently from the weight assigned to within-cluster contrasts. The next calculation shows the resulting inverse-covariance weighting; it is a component of the GEE equation, not by itself a regression estimate.

Worked Example: Weighting a Residual Vector

Consider a cluster of three observations with common working variance 4, \(\rho=0.20\), and residual vector \(\mathbf r=(2,-1,1)^{\mathsf T}\). Thus \(\mathbf V_i=4\mathbf R_i(0.20)\), and

$$ \mathbf R_i(0.20)= \begin{pmatrix} 1&0.20&0.20\\ 0.20&1&0.20\\ 0.20&0.20&1 \end{pmatrix}. $$

Using the inverse identity, with \(1-\rho=0.80\) and \(1+2\rho=1.40\),

$$ \mathbf R_i^{-1} =1.25\left(\mathbf I_3-\frac{0.20}{1.40}\mathbf 1_3\mathbf 1_3^{\mathsf T}\right) =1.25\left(\mathbf I_3-\frac{1}{7}\mathbf 1_3\mathbf 1_3^{\mathsf T}\right). $$

The residual sum is \(2+(-1)+1=2\), so \(\mathbf 1_3\mathbf 1_3^{\mathsf T}\mathbf r=(2,2,2)^{\mathsf T}\). Therefore,

$$ \mathbf V_i^{-1}\mathbf r =\frac{1}{4}\mathbf R_i^{-1}\mathbf r =\frac{1}{4}(1.25) \left[ \begin{pmatrix}2\\-1\\1\end{pmatrix} -\frac{1}{7}\begin{pmatrix}2\\2\\2\end{pmatrix} \right] \approx \begin{pmatrix} 0.5357\\ -0.4018\\ 0.2232 \end{pmatrix}. $$

Under working independence with the same variance, the weighted residual would instead be \(\mathbf r/4=(0.5000,-0.2500,0.2500)^{\mathsf T}\). The difference illustrates how positive within-cluster correlation changes the contributions entering the estimating equation. The ultimate effect on a coefficient also depends on \(\mathbf D_i\) and on contributions from all clusters.

Estimating the Working Correlation

In practice, \(\rho\) is usually estimated iteratively alongside the mean-model parameters. A common moment idea is to calculate standardized residuals using the fitted marginal means and variances, then summarize their products for distinct pairs in the same cluster. If those residuals have approximately unit variances, their pairwise products provide information about within-cluster correlation.

The following pooled pair-product calculation illustrates that idea. It is not a universal finite-sample estimator: implementations can use adjustments for fitted means, dispersion, or cluster size, and may constrain an estimate to the admissible range.

Worked Example: A Simple Moment Estimate

Suppose a hypothetical continuous-outcome analysis has three clusters, each with three observations. After fitting the marginal mean and scaling residuals by their estimated standard deviations, the standardized residual vectors are \((1,1,0)\), \((1,0,1)\), and \((0,1,1)\). There are three distinct pairs per cluster and thus nine pair products altogether.

For the first cluster, the products are \(1(1)=1\), \(1(0)=0\), and \(1(0)=0\), with sum 1. For the second cluster, the products are \(1(0)=0\), \(1(1)=1\), and \(0(1)=0\), also with sum 1. For the third cluster, they are \(0(1)=0\), \(0(1)=0\), and \(1(1)=1\), again with sum 1. The pooled average is therefore

$$ \hat{\rho}_{\text{moment}} =\frac{1+1+1}{3\times 3} =\frac{3}{9} =0.3333. $$

For clusters of size three, this value lies within \(-1/2<\rho<1\). It suggests positive average residual association under this simple calculation. With only three clusters, however, the estimate is highly uncertain; it should not be treated as compelling evidence that the true correlations are all equal to 0.3333.

Assessing Suitability and Recognizing Failure

Exchangeable correlation is most plausible when the observations within a cluster are substantively symmetric: there is no strong reason to expect one pair to be more associated than another after accounting for the mean model and marginal variances. It can be a useful parsimonious working choice when within-cluster dependence is present but the study does not call for a more detailed pattern.

Assess suitability by examining residual dependence in the context of the design. For repeated measures, compare residual association for nearby and distant visits; for clustered sites, consider whether shared features of the cluster plausibly affect all pairs similarly. Also check whether the estimated \(\rho\) is near a boundary, whether an attempted estimate violates the positive-definiteness range, and whether the fitting procedure reports a singular or non-invertible working covariance. These signs may indicate an unsuitable structure, sparse information, or numerical difficulty; they do not identify a single cause by themselves.

The following distinctions help keep the interpretation precise:

Approach or featureWhat it assumes or targetsImportant distinction
Exchangeable working correlationOne common working correlation for all distinct within-cluster pairsParsimonious; does not represent pair-specific time separation
Independence working correlationZero working correlation within clustersSimpler weighting; can still be used in GEE when outcomes are dependent, with appropriate robust inference
GLMM with random effectsA conditional outcome model with dependence induced by shared random effectsDifferent model target and assumptions; not merely another way to specify the same working matrix

The earlier material on independence working correlation introduced the zero-correlation working choice. Exchangeable correlation adds one dependence parameter while remaining parsimonious. A GLMM instead specifies a conditional model and a random-effects distribution; its implied marginal dependence need not be exchangeable.

Limitations and a Common Pitfall

A single \(\rho\) can be too restrictive when within-cluster association varies systematically across pairs. In repeated measures, for example, a constant correlation for observations separated by one visit and observations separated by many visits may be implausible. Exchangeability also cannot describe different correlations for distinct pairs that share the same cluster, such as pairs from different subgroups. Even when the working structure is only approximate, the mean model and independent-cluster sampling assumptions remain important; a chosen correlation pattern does not repair a misspecified marginal mean.

Common pitfall: “The fitted exchangeable \(\hat{\rho}\) is 0.30, so every pair in the population truly has correlation 0.30.” This overstates what the working parameter establishes. The estimate summarizes dependence under a chosen working structure; it does not prove equal pairwise correlations. Check the design and residual patterns, and distinguish the working assumption from a claim about the true covariance.

Another mistake is to use a value of \(\rho\) that makes the working matrix singular or invalid. For cluster size \(n_i\), check \(-1/(n_i-1)<\rho<1\) whenever \(n_i\geq2\); with a common parameter across clusters, check the largest cluster size. A numerically accepted value is not automatically a scientifically suitable one.

Check Your Understanding

Answer each question, then compare your reasoning with the solutions.

  1. For a cluster of size four, write the exchangeable matrix and state the admissible range for \(\rho\).
  2. For cluster size three, would \(\rho=-0.60\) define a positive-definite exchangeable correlation matrix? Show the decisive calculation.
  3. In one sentence, explain what exchangeability assumes about measurements at near and distant visits.
  4. Three clusters of size two have standardized residual pairs \((1,1)\), \((1,-1)\), and \((0,1)\). What is the pooled average pair product?

Solutions. (1) The matrix is \(\begin{pmatrix}1&\rho&\rho&\rho\\ \rho&1&\rho&\rho\\ \rho&\rho&1&\rho\\ \rho&\rho&\rho&1\end{pmatrix}\), and the range is \(-1/3<\rho<1\). (2) No. For \(n_i=3\), the lower bound is \(-1/2\); equivalently, the eigenvalue in the all-ones direction is \(1+2(-0.60)=-0.20\), which is negative. (3) Exchangeability assigns the same working correlation to every distinct pair, whatever their time separation. (4) There is one pair product per cluster: \(1(1)=1\), \(1(-1)=-1\), and \(0(1)=0\). The pooled average is \((1-1+0)/3=0\).

Clinical Biostats