# Doubt regarding mixed modeling format

Say, I have a dataset that looks at how many times my 5 babies chases a cat around the house . I'm trying to estimate 'y' which is the number of times the cat runs one complete round around the house as a function of the color of the dress the babies wear and the speed at which the babies are walking. But, I also have information about the type of food the babies ate and if the weather is cloudy or sunny on that specific day. What food the baby chooses to eat can be dependent on the weather.

I want to estimate y as fn of color and speed:

Now, my model is 'y'~color*speed+(1|baby)

But, I'm wondering if I can also add information about the food and weather, which are not part of my fixed effects into my model( without including interactions)

'y'~color*speed+(food||baby)+(food||weather)

Also note that in your 2nd model the || syntax means, at least in the lme4 package, that the software will not estimate a correlation between the random slopes and the random intercepts
• Yes that is literally what you asked for in the question:*"But, I'm wondering if I can also add information about the food and weather, which are not part of my fixed effects into my model"*. Please ask a new question about how to visualise a mixed model with random slopes for a variable but no fixed effect for that variable in a simple model such as y ~ 1 + (var | subject) – Robert Long Jul 5 at 16:28