Margaret Gorlin
2007-Dec-02 19:12 UTC
[R] error message in lmer for logistic regression model with random intercept and slope
Greetings, I am trying to run a logistic regression model for binary data with a random intercept and slope in R 2.6.1. When I use the code: lmer1<-lmer(infect ~ time+gender + (1+time|id), family=binomial, data=ichs, method="Laplace") Then from: summary(lmer1) I get the message: Error in if (any(sd < 0)) return("'sd' slot has negative entries") : missing value where TRUE/FALSE needed The model with just a random intercept has no difficulty. That is the model: lmer1<-lmer(infect ~ time+gender + (1|id), family=binomial, data=ichs, method="Laplace") yields no such message. Can someone please tell me what this is about and how to remedy? Thank you, Margaret Gorlin PhD Student UMDNJ SPH [[alternative HTML version deleted]]