Tutorials › Regression Analysis (Undergraduate) › Residual Confounding from Imperfect Measurement

Adjusted Associations and Confounding · Tutorial 189 of 991

Residual Confounding from Imperfect Measurement

Learn why adjusting for a noisy confounder may leave residual association, and how measurement and subject-matter information help assess the limitation.

Intermediate 10 min read

What You'll Learn

  • Distinguish a true confounder from an imperfectly measured version used in regression.
  • Explain residual confounding under a stated linear model with classical measurement error.
  • Calculate the remaining bias in worked examples using variances and covariances.
  • Identify the assumptions behind a reliability calculation from repeated measurements.
  • List the measurement and association information needed to assess residual confounding.

Why Measurement Quality Matters

Adjusting for a confounder can help separate an exposure–outcome association from the association created by a shared cause. But the variable entered into a regression is sometimes only a measurement or proxy for that cause. If it records the confounder imperfectly, adjustment for the recorded value need not remove all of the confounding. The remaining distortion is called residual confounding.

For example, suppose a true characteristic \(C\) is related to both an exposure \(X\) and an outcome \(Y\), but the data contain only a questionnaire-based measurement \(W\) of \(C\). The regression can adjust for \(W\), not directly for the unobserved \(C\). How much residual confounding remains depends not just on whether \(W\) is noisy, but also on how \(C\) relates to \(X\) and \(Y\), and on the nature of the measurement error.

Definition: Residual confounding from imperfect measurement occurs when adjustment for an observed, error-prone measurement of a confounder does not remove the association between the exposure and outcome that is attributable to the true confounder. It is distinct from confounding by an entirely unmeasured variable: some information about the confounder is used, but that information is incomplete.

A Model for the Problem

To make the mechanism precise, consider centered continuous variables and the following linear model:

$$ Y=\beta_X X+\beta_C C+\varepsilon,\qquad X=\gamma_C C+u,\qquad W=C+v. $$

Here \(C\) is the true confounder, \(W\) is its observed measurement, and \(u\), \(v\), and \(\varepsilon\) are errors. For the examples below, assume the model is additive and linear, the variables have finite variances, and \(u\), \(v\), and \(\varepsilon\) have mean zero and are mutually independent of one another and of \(C\). In particular, the measurement error \(v\) is independent of the true confounder, exposure error, and outcome error; this is the classical additive measurement-error setup. These are simplifying assumptions, not facts guaranteed by collecting data.

The coefficient \(\beta_C\) describes the relationship between \(C\) and \(Y\) at a fixed \(X\), while \(\gamma_C\) describes how \(C\) is related to \(X\). If either relationship is absent, this model has no confounding through \(C\): a confounder must be relevant to both sides of the exposure–outcome relationship. In applications, a causal interpretation also requires appropriate causal assumptions. The calculations here first describe regression coefficients and residual confounding under the stated model.

If \(C\) were observed without error and included in the regression, the population coefficient of \(X\) would be \(\beta_X\), under this model. When the regression instead includes \(W\), the coefficient of \(X\) can differ from \(\beta_X\). The next result expresses that difference.

Result: In a population regression of \(Y\) on \(X\) and \(W\), the coefficient of \(X\) is \(\beta_X+\beta_C\delta_X\), where \(\delta_X\) is the coefficient of \(X\) in the population regression of \(C\) on \(X\) and \(W\). Thus the residual confounding in this model is \(\beta_C\delta_X\). It is zero if \(C\) is measured perfectly, or if the confounder has no relationship with the outcome or exposure in the model.

Why Error-Prone Adjustment Leaves a Remainder

The result follows by separating the part of each variable explained by \(W\). Write \(X^\ast\) for the residual from the population linear regression of \(X\) on \(W\), and \(C^\ast\) for the residual from the population linear regression of \(C\) on \(W\). The coefficient of \(X\) in the regression of \(Y\) on \(X\) and \(W\) equals the coefficient from regressing the residualized \(Y\) on \(X^\ast\). Residualizing the outcome model with respect to \(W\) gives \(Y^\ast=\beta_X X^\ast+\beta_C C^\ast+\varepsilon^\ast\). Independence and mean-zero errors make \(\varepsilon^\ast\) uncorrelated with \(X^\ast\), so the coefficient is:

$$ \frac{\operatorname{Cov}(X^\ast,Y^\ast)} {\operatorname{Var}(X^\ast)} = \beta_X+ \beta_C\frac{\operatorname{Cov}(X^\ast,C^\ast)} {\operatorname{Var}(X^\ast)} = \beta_X+\beta_C\delta_X. $$

The last fraction is exactly \(\delta_X\), the coefficient of \(X\) in the regression of \(C\) on \(X\) and \(W\). With a perfect measurement, \(W=C\), the part of \(C\) not explained by \(W\) is zero, so \(\delta_X=0\). With a noisy measurement, \(W\) does not fully account for \(C\); the part of \(C\) remaining after adjustment can still vary with \(X\), making \(\delta_X\) nonzero.

This derivation is specific to the stated linear model and its error assumptions. In particular, it does not say that every measurement error simply shrinks a coefficient toward zero. Measurement error in a confounder can leave bias in an exposure coefficient, and departures from the classical assumptions can change the direction and size of that bias.

Worked Example: Adjusting for a Noisy Confounder

Consider a hypothetical population in which \(C\), \(X\), and \(W\) are centered. Let \(X=C+u\) and \(W=C+v\), with \(\operatorname{Var}(C)=\operatorname{Var}(u)=\operatorname{Var}(v)=1\), and let the errors be independent as specified above. Suppose the outcome model is \(Y=2X+3C+\varepsilon\). What is the coefficient of \(X\) when the regression adjusts for \(W\) rather than \(C\)?

First calculate the covariances needed for the regression of \(C\) on \(X\) and \(W\). Independence gives \(\operatorname{Var}(X)=2\), \(\operatorname{Var}(W)=2\), \(\operatorname{Cov}(X,W)=1\), and \(\operatorname{Cov}(C,X)=\operatorname{Cov}(C,W)=1\).

For two predictors, the coefficient of \(X\) in the regression of \(C\) on \(X\) and \(W\) is:

$$ \delta_X= \frac{\operatorname{Cov}(C,X)\operatorname{Var}(W) -\operatorname{Cov}(C,W)\operatorname{Cov}(X,W)} {\operatorname{Var}(X)\operatorname{Var}(W)-\operatorname{Cov}(X,W)^2} = \frac{(1)(2)-(1)(1)}{(2)(2)-1^2} = \frac{1}{3}. $$

Therefore, the coefficient of \(X\) after adjusting for \(W\) is:

$$ \beta_X+\beta_C\delta_X = 2+3\left(\frac{1}{3}\right) = 3. $$

The regression adjusting for the noisy measurement has a population coefficient of 3 outcome units per exposure unit, compared with 2 outcome units per exposure unit in the model adjusted for the true \(C\). The remaining difference is 1 outcome unit per exposure unit. It arises because the imperfect adjustment leaves some of the relationship between \(C\) and \(X\) in the exposure coefficient. This is a model-based illustration, not a causal conclusion about real people or a real study.

How the Amount of Error Can Matter

A useful way to see the role of measurement quality is to vary the error variance while holding the exposure model and outcome model fixed. Suppose \(\operatorname{Var}(C)=1\), \(X=C+u\), and \(W=C+v\), with \(\operatorname{Var}(u)=1\) and \(\operatorname{Var}(v)=\tau^2\). Keep the independence assumptions from the model. The variance of \(W\) is \(1+\tau^2\), and \(\operatorname{Cov}(X,W)=\operatorname{Cov}(C,W)=\operatorname{Cov}(C,X)=1\). Substituting into the same regression-coefficient formula gives:

$$ \delta_X= \frac{(1)(1+\tau^2)-(1)(1)} {(2)(1+\tau^2)-1^2} = \frac{\tau^2}{1+2\tau^2}. $$

For this particular setup, \(\delta_X=0\) when \(\tau^2=0\), as expected for a perfect measurement. As \(\tau^2\) increases, adjustment accounts for less of the true confounder. This formula describes this specified model; it is not a universal conversion from a reliability value to residual bias.

Worked Example: Comparing Two Measurement Error Levels

Keep the hypothetical outcome model \(Y=2X+3C+\varepsilon\) and the exposure model \(X=C+u\), with \(\operatorname{Var}(C)=\operatorname{Var}(u)=1\). Now suppose the measurement error variance is \(\operatorname{Var}(v)=0.25\). Find the coefficient of \(X\) in the regression adjusting for \(W\).

Here \(\operatorname{Var}(W)=1.25\), while the three covariances \(\operatorname{Cov}(C,X)\), \(\operatorname{Cov}(C,W)\), and \(\operatorname{Cov}(X,W)\) each equal 1. Thus:

$$ \delta_X= \frac{(1)(1.25)-(1)(1)} {(2)(1.25)-1^2} = \frac{0.25}{1.5} = \frac{1}{6}. $$

The adjusted coefficient is therefore:

$$ 2+3\left(\frac{1}{6}\right)=2.5. $$

It is 0.5 outcome units per exposure unit above the coefficient of 2 in the model adjusted for \(C\). For comparison, the simple variance ratio \(\operatorname{Var}(C)/\operatorname{Var}(W)=1/1.25=0.8\) is sometimes called reliability in this classical setup. Knowing that ratio alone does not generally determine the residual bias: the relationship between \(C\) and \(X\), the relationship between \(C\) and \(Y\), and the measurement-error process also matter.

What Measurement Information Is Needed?

An observed regression coefficient and a vague statement that a confounder was measured “with some error” are not enough to calculate how much residual confounding remains. The result above depends on \(\beta_C\) and \(\delta_X\): the outcome relationship with \(C\), and the remaining association between \(C\) and \(X\) after accounting for \(W\). Estimating or bounding these quantities requires information about the measurement process and the role of the true confounder.

Useful information may come from a validation sample in which both \(C\) and \(W\) are measured, or from repeated measurements of \(C\) using a method with known properties. For a continuous confounder measured as \(W=C+v\), relevant information includes the scale and variance of \(C\), the variance of measurement error, and evidence about whether that error is independent of \(C\), \(X\), and \(Y\). For a categorical confounder, sensitivity and specificity—probabilities of recording the observed category given the true category—may be relevant, along with the prevalence of the true categories. The appropriate information depends on the measurement scale and model.

Repeated measurements can help under explicit assumptions. If two measurements are \(W_1=C+v_1\) and \(W_2=C+v_2\), and their errors are independent of each other and of \(C\), then \(\operatorname{Cov}(W_1,W_2)=\operatorname{Var}(C)\). This identity can help estimate the true-confounder variance and measurement-error variance from repeated records. Without the independence and equal-scale assumptions, the covariance need not identify those quantities in this way.

Worked Example: Using Replicate Measurements

Suppose a hypothetical validation exercise records two measurements \(W_1\) and \(W_2\) of a continuous confounder. Assume \(W_j=C+v_j\), with independent errors of equal variance, each independent of \(C\). The observed population variances are \(\operatorname{Var}(W_1)=\operatorname{Var}(W_2)=1.5\), and the covariance is \(\operatorname{Cov}(W_1,W_2)=1\). What does this imply under the stated assumptions, and what residual bias follows in the earlier model?

Because the measurement errors are independent across replicates, their covariance is zero. Hence:

$$ \operatorname{Var}(C)=\operatorname{Cov}(W_1,W_2)=1,\qquad \operatorname{Var}(v_j)=\operatorname{Var}(W_j)-\operatorname{Var}(C) =1.5-1=0.5. $$

The reliability ratio for either measurement is \(1/1.5=2/3\). Now use the earlier exposure model \(X=C+u\), with \(\operatorname{Var}(u)=1\), and outcome model \(Y=2X+3C+\varepsilon\). Here \(\operatorname{Var}(C)=1\), \(\operatorname{Var}(W)=1.5\), and \(\operatorname{Cov}(C,X)=\operatorname{Cov}(C,W)=\operatorname{Cov}(X,W)=1\). Therefore:

$$ \delta_X= \frac{(1)(1.5)-(1)(1)} {(2)(1.5)-1^2} = \frac{0.5}{2} = 0.25, \qquad \beta_C\delta_X=3(0.25)=0.75. $$

Under this model, adjustment using one replicate leaves a residual difference of 0.75 outcome units per exposure unit, giving a coefficient of \(2+0.75=2.75\). The calculation depends on the replicate-error assumptions and the specified associations with \(X\) and \(Y\). The reliability estimate by itself would not establish this bias in a different setting.

Limits and a Common Mistake

The classical model is useful because it shows a clear mechanism, but measurement error is not always classical. A self-report might be less accurate for people with high exposure; an instrument might systematically over- or under-record values; or error might depend on health status. In such cases \(W=C+v\) with independent \(v\) may not be a reasonable description. The direction of residual confounding may then differ from the examples, and a simple reliability ratio cannot settle the issue.

A common mistake is to say, “We adjusted for the confounder, so confounding has been removed.” That conclusion treats the recorded measurement as if it were the true variable. The correction is to ask whether the measured variable captures the relevant variation in the confounder, how measurement error behaves, and whether the confounder is related to both exposure and outcome. If those features are uncertain, report the adjusted association with that limitation and seek validation data or a sensitivity analysis rather than claiming the bias is absent.

Imperfect measurement does not prove that a particular adjusted estimate is biased by a particular amount. It identifies a plausible limitation whose impact must be assessed using additional information and assumptions. This distinction matters: the examples calculate bias only because their hypothetical model and error structure are fully specified.

Key takeaway: Adjusting for a noisy measurement of a confounder can leave an exposure–outcome coefficient partly influenced by the true confounder. Assessing the size and direction of that residual confounding requires information about measurement error and about the confounder’s relationships with exposure and outcome, together with defensible assumptions.

Check Your Understanding

Use the model assumptions stated in the tutorial when answering the calculation questions.

  1. In the linear model, what are \(\beta_C\) and \(\delta_X\), and how do they combine to give the residual confounding?
  2. If \(W=C+v\) and \(\operatorname{Var}(v)=0\), what happens to the residual confounding under the model? Explain why.
  3. In the comparison example with \(\operatorname{Var}(v)=0.25\), why is the adjusted coefficient 2.5 rather than 2?
  4. What independence assumptions make the covariance of two replicate measurements informative about \(\operatorname{Var}(C)\)?
  5. Why is a reliability value alone insufficient to determine the residual confounding in a new setting?