pitakakariki / simr

Power Analysis of Generalised Linear Mixed Models by Simulation
70 stars 20 forks source link

Error message about fixed effects #95

Open psyargh opened 6 years ago

psyargh commented 6 years ago

Hi all,

I'm very new to this, so I apologize if this has been already asked. This is the model for which I'm trying to determine power:

model1 <- glmer(y ~ (x1+x2)*x3*x4 + (1|x5) + (1|x6) + (1|x7), family="poisson", data=sim)
summary(model1)

This part converges.

powerSim(model1)

I get the following error message: "Couldn't automatically determine a default fixed effect for this model."

What's the issue here? Should I provide more information?

pitakakariki commented 6 years ago

powerSim uses the first fixed effect by default. e.g. if you had ~ x1 + x2 + x3 + ... it would test x1. In this case, with a more complex fixed effects specification, you'll need to choose a test manually with the test= argument.