R lme4 nested fixed effects. Do I nest as random effects? -


i fitting model in glmer (although same question applies lmer).

however have 2 (what think are) nested fixed effects. testing how long people spend eating compared sex , weight. how heavy depends on sex (the distribution of weights different between sexes), care in model. want test whether heaviest women eats more lightest women , heaviest man eats more lightest man, want 1 model see if there population wide effect.

this how thought of doing having 2 fixed effects nested random effect:

model <- glmer(timeeating ~ sex + weight + (1|sex:weight),        data, family = poisson(link = "log")) 


Comments

Popular posts from this blog

python - Subclassed QStyledItemDelegate ignores Stylesheet -

java - HttpClient 3.1 Connection pooling vs HttpClient 4.3.2 -

SQL: Divide the sum of values in one table with the count of rows in another -