I want to specify a linear mixed model with one dependent variable (DV) and two independent variables (IV). Furthermore, I want to add random intercepts for each of my participant but just for my first (IV1) and not the second (IV2) independent variable. How do I specify that using lme4 in R?
Currently I use the following specification, which in my understanding includes the random intercepts for both of my IVs.
DV ~ 1 + IV1 + IV2 + IV1:IV2 + (1|participant).
With IV1 and IV2 being my fixed effects, IV1:IV2 representing an interaction between my fixed effects and (1|participant) representing my random intercepts.
However I want to specify random intercepts per participant for my IV1 only. How do I do that?
Thanks a lot :)