# biased estimation of variable correlated with endogenous variable

I have the following model:

$$X = \alpha_1 + aZ + \epsilon_1 \\ Y = \alpha_2 + bZ + cX + \epsilon_2$$

Suppose that $$Z$$ is randomly assigned but $$X$$ is correlated with the error term $$\epsilon_2$$, in particular because $$Cov(\epsilon_1, \epsilon_2) \neq 0$$. So $$X$$ suffers from omitted variable bias and regressing $$Y$$ on $$X$$ and $$Z$$ will lead to a biased estimate $$\widehat{c}$$ for $$c$$. But there is also a spillover bias on estimated coefficient $$\widehat{b}$$ for $$Z$$. Can you provide an intuitive explanation how the omitted variable bias for $$X$$ spills over to $$Z$$, even though it was randomly assigned?

• Hi: The use of the term "omitted variable bias" is more econometric term than statistical but the assumption in omitted variable bias is that the missing variable is correlated with all of the independent variables so both estimates (b hat and c hat) will be biased. Note that, even though Z is randomly assigned, if it's correlated with the missing variable, this still causes estimation bias. The link provided gives a clearer and more detailed explanation of omitted variable bias than I could. en.wikipedia.org/wiki/Omitted-variable_bias Commented Nov 10, 2023 at 6:28
• How could Z become correlated with $\epsilon_2$ if it is randomly assigned? Z will be correlated with X because it causes it to change by first equation. But since Z is not related to any other variable according to the structural model above, it shouldn't be correlated with $\epsilon_2$? Commented Nov 10, 2023 at 14:55
• Hi: Just because a variable is randomly assigned, doesn't mean there can't be bias on the estimated coefficient. You agree that $\hat{c}$ is biased so what keeps $\hat{b}$ from being biased if for no other reason than to offset the bias of $\hat{c}$. In the end, one is trying to minimize the difference of $Y$ and $\hat{Y}$ so, once $\hat{c}$ is biased ( in one direction), my intuition is that all bets are off as far as the unbiasedness of the $\hat{b}$. It could be biased in the opposite direction of $\hat{c}$. But I could be mistaken here. Hopefully someone else can comment or correct. Commented Nov 12, 2023 at 2:08

Maybe I misunderstand the setup, but I do not directly see this spillover bias:

By linear projection theory, least squares on the equation for $$Y$$ will, for $$D=(Z\; X)$$ and $$\hat\beta$$ the vector of coefficients on $$D$$, tend to $$\text{plim}\,\hat\beta=Var(D)^{-1}Cov(D,Y)$$ Since $$Z$$ is randomly assigned, I would argue that this entails that $$Cov(Z,X)=0$$. Hence, $$Var(D)^{-1}=\frac{1}{V_XV_Z}\begin{pmatrix}V_X&0\\0&V_Z\end{pmatrix}$$ Thus, $$\text{plim}\,\hat b=\frac{1}{V_XV_Z}V_XCov(Z,Y)=\frac{Cov(Z,Y)}{V_Z}$$ Now, $$Cov(Z,Y)=Cov(Z,\alpha_2 + bZ + cX + \epsilon_2)=bV_Z$$ so that $$\text{plim}\,\hat b=b,$$ provided $$Cov(Z,\epsilon_2)=0$$.

Here is an example that illustrates my point (taking $$\alpha_1=\alpha_2=0$$ w.l.o.g., and $$a=0$$ in view of random assignment, so that $$X=\epsilon_1$$, basically):

library(mvtnorm)
n <- 30000
X.eps <- rmvnorm(n, sigma = matrix(c(1, 0.5, 0.5, 1), ncol=2))
X <- X.eps[,1]
eps2 <- X.eps[,2]
Z <- rnorm(n)
b.coeff <- 2
c.coeff <- 3
Y <- b.coeff*Z + c.coeff*X + eps2

> summary(lm(Y~Z+X))

Call:
lm(formula = Y ~ Z + X)

Residuals:
Min      1Q  Median      3Q     Max
-3.5277 -0.5872  0.0015  0.5851  4.0954

Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) -0.004004   0.005045  -0.794    0.427
Z            1.996282   0.005040 396.051   <2e-16 ***
X            3.494961   0.005054 691.535   <2e-16 ***
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Residual standard error: 0.8738 on 29997 degrees of freedom
Multiple R-squared:  0.9547,    Adjusted R-squared:  0.9547
F-statistic: 3.164e+05 on 2 and 29997 DF,  p-value: < 2.2e-16

• Thanks for this reply. Unfortunately, $Cov(X,Z)$ is not zero since $Z$ affects the value of $X$ by the first equation. Once you realize value of $Z$ that determines what $X$ becomes, hence they are correlated. Commented Nov 10, 2023 at 14:59
• OK, I see. I would then consider rethinking the wording as, at least to me, this is not quite random assignment of a regressor. If $X$ and $Z$ are correlated, you can plug those covariances into my results to derive the asymptotic bias of the estimator (which, to be sure, is not really the "intuition" you asked for - but it would basically then be this covariance which spills over the bias) Commented Nov 10, 2023 at 15:16
• To me, random assignments covers examples like soil quality (how much sunshine does a parcel get etc.) etc. affecting harvests (and where there is OVB in that soil quality might be correlated with further determinants of harvests, say, protection from wind drying the land), and one then additionally randomly assigns fertilizer to parcels. In your model, there would then be an additional channel where fertilizer affects that soil quality, or is chosen as a function of soil quality. Then you neither consistently estimate the effect of soil quality nor of fertilizer, because the Commented Nov 10, 2023 at 15:31
• fertilizer coefficient "inherits" bias from the biased soil quality coefficient due to correlation Commented Nov 10, 2023 at 15:36
• yes that's the right example to think about this. As you said, the bias spills over to the fertilizer even though fertilizer was randomly assigned (fertilizer is independent of other unobserved covariates like wind protection). I was hoping to find a good intuitive explanation behind this. Commented Nov 10, 2023 at 20:35