Tutorials › Econometrics (Graduate) › CR2 and CR3 Leverage Adjustments

Clustered and Dependent Errors · Tutorial 128 of 952

CR2 and CR3 Leverage Adjustments

Learn how CR2 and CR3 transform cluster residuals to address leverage-related bias, and calculate what those adjustments do in practice.

Advanced 10 min read

What You'll Learn

  • Define cluster leverage from the diagonal blocks of the regression hat matrix.
  • Derive the CR2 adjustment under a homoskedastic working model.
  • Explain how CR3 relates to deleting one cluster from the regression.
  • Calculate adjusted residuals and compare their leverage amplification.
  • Identify why clusters with high leverage can matter disproportionately.
  • Distinguish working-model bias correction from a guarantee of exact unbiasedness.

Why Adjust Cluster Residuals by Cluster?

A clustered covariance estimator is built from cluster-level score contributions. In ordinary least squares, a cluster’s contribution depends on its regressors and its regression residuals. But residuals are not the unobserved errors: fitting the regression has already used the data to reduce them. That reduction can be especially pronounced for observations in a high-leverage cluster, making the unadjusted cluster contribution too small under a useful reference model.

CR2 and CR3 address this problem by transforming each cluster’s residual vector before forming its contribution to the covariance estimate. Both use the cluster’s block of the hat matrix. CR2 calibrates residuals to remove a particular working-model bias; CR3 makes a stronger adjustment connected to deleting a cluster and refitting. Neither adjustment makes arbitrary clustered-error covariance known or guarantees exact finite-sample inference.

Setup and notation: Let \(y=X\beta+u\) be a linear regression with \(N\) observations and a full-column-rank design matrix \(X\). Observations are partitioned into \(G\) clusters. For cluster \(i\), let \(y_i\) and \(e_i=y_i-X_i\hat\beta\) denote its outcome and OLS residual vectors, and let \(X_i\) be its design matrix. The hat matrix is \(H=X(X'X)^{-1}X'\); its cluster \(i\) diagonal block is \(H_{ii}=X_i(X'X)^{-1}X_i'\). The residual-maker is \(M=I-H\).

The unadjusted cluster-robust covariance estimator, before any overall finite-sample scaling, has the form

$$ \widehat V_{\mathrm{CR0}} =(X'X)^{-1} \left(\sum_{i=1}^{G}X_i'e_i e_i'X_i\right) (X'X)^{-1}. $$

An adjusted version replaces \(e_i\) by \(A_i e_i\) inside each cluster’s contribution. The adjustment matrix \(A_i\) is symmetric in the standard CR2 and CR3 constructions described here. This tutorial uses the homoskedastic working model to derive the standard CR2 adjustment, and the ordinary least-squares leave-one-cluster-out construction to motivate CR3.

Cluster Leverage and the CR2 Adjustment

The matrix \(H_{ii}\) describes the part of the fitted values in cluster \(i\) that is associated with observations in that same cluster. Its eigenvalues lie between zero and one. Directions in the cluster’s residual vector that correspond to eigenvalues near one have been strongly reduced by fitting the regression. The inverse adjustment therefore needs to amplify residuals more in those directions.

Definition: Under the homoskedastic working model, the CR2 adjustment is $$ A_i^{\mathrm{CR2}}=(I_i-H_{ii})^{-1/2}, $$ where \(I_i\) is the identity matrix for the observations in cluster \(i\), and the inverse square root is the symmetric matrix inverse square root. The adjustment exists when \(I_i-H_{ii}\) is positive definite.

The working model for this definition is \(E[u\mid X]=0\) and \(\operatorname{Var}(u\mid X)=\sigma^2 I\): conditional on the design, errors have mean zero and a common variance with no cross-observation covariance. This model is a reference for calibrating the adjustment, not a requirement that the errors in the substantive application truly be independent and homoskedastic.

Worked Example: Computing CR2 and CR3 for a Cluster

Suppose a hypothetical regression has two observations in a cluster, with \(H_{ii}=\begin{pmatrix}0.25&0\\0&0.50\end{pmatrix}\), and the cluster’s residual vector is \(e_i=(2,-1)'\). Compute the CR2 and CR3 adjusted residuals.

Because \(H_{ii}\) is diagonal, \(I_i-H_{ii}=\begin{pmatrix}0.75&0\\0&0.50\end{pmatrix}\). Its inverse square root is $$ A_i^{\mathrm{CR2}} =\begin{pmatrix}1/\sqrt{0.75}&0\\0&1/\sqrt{0.50}\end{pmatrix} \approx\begin{pmatrix}1.1547&0\\0&1.4142\end{pmatrix}. $$ Thus, using the unrounded factors for the multiplication, $$ A_i^{\mathrm{CR2}}e_i \approx\left((1/\sqrt{0.75})\times2,\ (1/\sqrt{0.50})\times(-1)\right)' \approx(2.309,-1.414)'. $$

CR3 uses the inverse rather than the inverse square root: $$ A_i^{\mathrm{CR3}}=(I_i-H_{ii})^{-1} =\begin{pmatrix}1/0.75&0\\0&1/0.50\end{pmatrix} =\begin{pmatrix}1.333&0\\0&2\end{pmatrix}. $$ Therefore \(A_i^{\mathrm{CR3}}e_i=(2.667,-2)'\). Both adjustments leave neither component unchanged; CR3 amplifies each more than CR2 in this example.

Why CR2 Corrects Working-Model Bias

The derivation follows from the covariance of OLS residuals. Conditional on \(X\), the residual vector is \(e=My\), and the model implies \(e=Mu\). Since \(M\) is symmetric and idempotent, under the homoskedastic working model,

$$ \operatorname{Var}(e\mid X) =M(\sigma^2 I)M' =\sigma^2 M. $$

In particular, the covariance block for cluster \(i\)’s residuals is \(\sigma^2 M_{ii}=\sigma^2(I_i-H_{ii})\). The residuals have less variance in directions with high cluster leverage. Applying \(A_i^{\mathrm{CR2}}\) on both sides of this covariance block gives

$$ A_i^{\mathrm{CR2}}\operatorname{Var}(e_i\mid X) (A_i^{\mathrm{CR2}})' =\sigma^2(I_i-H_{ii})^{-1/2} (I_i-H_{ii}) (I_i-H_{ii})^{-1/2} =\sigma^2 I_i. $$

This shows exactly what the adjustment accomplishes: under the working model, the adjusted residual vector has covariance \(\sigma^2 I_i\). Consequently, the expected adjusted “meat” in the covariance estimator is

$$ E\!\left[\sum_{i=1}^{G}X_i'A_i^{\mathrm{CR2}}e_i e_i' (A_i^{\mathrm{CR2}})'X_i\mid X\right] =\sigma^2\sum_{i=1}^{G}X_i'X_i =\sigma^2 X'X. $$

Multiplying by \((X'X)^{-1}\) on each side yields \(\sigma^2(X'X)^{-1}\), the conditional covariance of OLS under the same working model. This is the bias-reduction logic: CR2 corrects the expected cluster contributions so they reproduce the working-model covariance. It does not establish that the estimator is exactly unbiased when the actual errors have arbitrary within-cluster dependence or heteroskedasticity.

Worked Example: Verifying the CR2 Covariance Correction

Return to the hypothetical two-observation leverage block \(H_{ii}=\operatorname{diag}(0.25,0.50)\). Under the homoskedastic working model, the residual covariance block is $$ \operatorname{Var}(e_i\mid X) =\sigma^2\operatorname{diag}(0.75,0.50). $$

The CR2 factors are \(1/\sqrt{0.75}\) and \(1/\sqrt{0.50}\). The adjusted covariance is therefore $$ A_i^{\mathrm{CR2}}\operatorname{Var}(e_i\mid X) (A_i^{\mathrm{CR2}})' =\sigma^2\operatorname{diag}\left( \frac{0.75}{0.75},\frac{0.50}{0.50}\right) =\sigma^2 I_2. $$

Each direction has been restored to variance \(\sigma^2\). This calculation explains the correction, rather than merely showing that CR2 multiplies residuals by numbers greater than one.

CR3 and Deleting One Cluster

CR3 is connected to the change in the coefficient estimate when one cluster is omitted. Let \(\hat\beta_{(-i)}\) be the OLS estimate using all clusters except \(i\), assuming the reduced design matrix still has full column rank. The normal equations for the full sample give \(X'e=0\). Evaluating the reduced-sample normal equations at the full-sample estimate leaves the discrepancy \(-X_i'e_i\), so the reduced estimate must correct for that discrepancy.

The relationship between the reduced and full design matrices gives the exact identity

$$ \hat\beta-\hat\beta_{(-i)} =(X'X)^{-1}X_i'(I_i-H_{ii})^{-1}e_i. $$

To see the leverage term, write \(X_{(-i)}'X_{(-i)}=X'X-X_i'X_i\). The matrix inverse identity for this deletion implies \((X_{(-i)}'X_{(-i)})^{-1}X_i'=(X'X)^{-1}X_i'(I_i-H_{ii})^{-1}\). Substituting this into the coefficient change obtained from the reduced normal equations yields the displayed expression. Thus the change associated with deleting a cluster involves the residuals amplified by \((I_i-H_{ii})^{-1}\), motivating the standard CR3 choice.

Definition: The standard CR3 cluster adjustment is $$ A_i^{\mathrm{CR3}}=(I_i-H_{ii})^{-1}. $$ It applies the same cluster-level leverage correction that appears in the full-versus-deleted coefficient relationship. CR3 is more aggressive than CR2 in directions with nonzero leverage below one.

This link is a motivation for the adjustment, not a claim that every CR3 covariance convention is identical to every jackknife variance formula. Implementations can differ in overall scaling or in how leave-one-cluster-out estimates are combined. When comparing results, specify the adjustment and any additional scaling rather than relying on the label alone.

Worked Example: Comparing Amplification at High Leverage

Consider a hypothetical cluster whose leverage block has eigenvalues \(0.75\) and \(0.50\). In corresponding orthogonal directions, suppose its residual components are \(0.40\) and \(-0.60\). Compute the adjusted components.

CR2 multiplies by the inverse square roots of one minus the eigenvalues: $$ 0.40/\sqrt{1-0.75}=0.800,\qquad -0.60/\sqrt{1-0.50}\approx-0.8485. $$ CR3 multiplies by their inverses: $$ 0.40/(1-0.75)=1.600,\qquad -0.60/(1-0.50)=-1.200. $$

The first direction has higher leverage, so it receives the larger amplification under both adjustments. CR3 is especially sensitive there: its factor is \(4\), compared with CR2’s factor \(2\). These are adjusted residual components, not coefficient effects by themselves; their effect on a covariance estimate also depends on the cluster’s regressors and the other clusters’ contributions.

When High-Leverage Clusters Matter

A cluster can have substantial leverage because it contains many observations, has unusual regressor values, or contributes information in a direction that is sparse elsewhere in the design. The relevant quantity is not just a single observation’s leverage: it is the spectrum of the block \(H_{ii}\). A cluster may have a high-leverage direction even if other directions in that same cluster have modest leverage.

As an eigenvalue \(h\) of \(H_{ii}\) approaches one, the corresponding adjustment factors grow:

$$ \text{CR2 factor}=(1-h)^{-1/2}, \qquad \text{CR3 factor}=(1-h)^{-1}. $$

If \(h=0.90\), the factors are about \(3.162\) and \(10\), respectively. If \(h=1\), the inverse does not exist. This is not a reason to replace the undefined calculation with an arbitrary large number: it signals a singular leave-one-cluster-out design in that direction, so deleting the cluster removes information needed to identify the regression coefficients.

Common Mistakes and Practical Interpretation

  • Using observation-level leverage in place of cluster leverage. CR2 and CR3 use the block \(H_{ii}\), which captures leverage jointly across a cluster. Separate diagonal elements alone do not describe its full leverage structure.
  • Claiming CR2 is exactly unbiased under any clustered errors. The derivation establishes the correction under a specified homoskedastic working model. With a different true covariance structure, that equality need not hold.
  • Treating CR3 as a universally superior replacement. Its stronger amplification can make estimates more sensitive to high-leverage clusters. The adjustment reflects a different bias-correction construction; it does not guarantee a better answer in every design.
  • Rounding adjustment factors too early. Compute with the matrix or factor at full precision, then round the reported result. For example, \(2/\sqrt{0.75}\approx2.309\); multiplying the rounded factor \(1.155\) by \(2\) instead gives \(2.310\).
  • Confusing an adjustment with a complete inference procedure. CR2 or CR3 specifies how residual contributions enter a covariance estimate. It does not, by itself, determine the reference distribution or degrees of freedom for a test.
Key takeaway: CR2 uses \((I_i-H_{ii})^{-1/2}\) to restore the residual covariance implied by a homoskedastic working model. CR3 uses \((I_i-H_{ii})^{-1}\), linked to deleting a cluster. Both emphasize high-leverage directions, but neither removes the need to examine the design and state the inferential procedure.

Check Your Understanding

Answer these questions by referring to the cluster block \(H_{ii}\) and the stated working model.

  1. For a leverage eigenvalue of \(0.64\), what are the CR2 and CR3 adjustment factors?
  2. Why does the CR2 derivation use the residual covariance block \(\sigma^2(I_i-H_{ii})\)?
  3. In what sense is CR3 connected to deleting a cluster from the regression?
  4. What does an eigenvalue of one in \(H_{ii}\) imply for the CR2 and CR3 adjustments?
  5. Why does the CR2 working-model calculation not prove unbiasedness under arbitrary within-cluster dependence?
Clinical Biostats