How do random effects adjust for confounding in a model? This post explains that they do just as fixed effects do. This makes sense intuitively. However, I don't understand how the inclusion of a random effect can change the estimated effect of a treatment on the outcome.
If a random intercept is assumed to have a mean of zero, wouldn't the other coefficients in the model be unaffected (only their standard errors would change)?
To make this more concrete: I want to estimate the effect of a medical treatment on death. I believe that the medical center is a confounder (the particular hospital affects both likelihood of the subject receiving the treatment and likelihood of the subject dying). Will including hospital as a random intercept adjust the estimated coefficient for treatment even though the expected value of the random effect for hospital is 0?