This is a test version of Biostars. For the public version, visit https://www.biostars.org.
adjusting for confounders in LMER in R

I am not very familiar with LMER and wonder if someone can confirm what I believe having read a while back. I am analysing the change in the composition of bacterial species between two time points. In my data set there are 6 confounding variables, I wish to adjust for. I believe they can be added as fixed variables into the base formula in lmer. Do I remember this correctly?

base: lmer(Y~X + (Z1 | g1)  # where Z is my random effect and g the grouping factor
adjusted: lmer(Y~X + a + b + c... + (Z1 | g1)  # were a,b,c.. are the confounders
confounders lmer r

0 answers

No answers yet.

Log in to answer this question.