[R-sig-ME] lmer random and fixed effect?

Charles Determan Jr deter088 at umn.edu
Thu Aug 14 20:08:58 CEST 2014


Greetings,

I have been looking more into mixed models recently and have run into a
situation that confuses me.  I was initially under the impression that
fixed and random effect variables are separate, however can they be both in
an lmer model and if so why would you do so?

Such as example is with the following dataset:
lmm.data <- read.table("
http://www.unt.edu/rss/class/Jon/R_SC/Module9/lmm.data.txt",
                       header=TRUE, sep=",", na.strings="NA", dec=".",
strip.white=TRUE)

Reading online, I have found the following model:
require(lme4)
fit <- lmer(formula = extro~open+agree+social+class+(1|school/class), data
= lmm.data)

Everything runs fine but I am confused as to what this actually means or if
it is even appropriate.

Thank you for any insight,
Regards,

-- 
Dr. Charles Determan, PhD
Integrated Biosciences

	[[alternative HTML version deleted]]



More information about the R-sig-mixed-models mailing list