[R] glm prb (Error in `contrasts<-`(`*tmp*`, value = "contr.treatment") : )
moleps
moleps2 at gmail.com
Sun Aug 29 21:13:42 CEST 2010
glm(A~B+C+D+E+F,family = binomial(link = "logit"),data=tre,na.action=na.omit)
Error in `contrasts<-`(`*tmp*`, value = "contr.treatment") :
contrasts can be applied only to factors with 2 or more levels
however,
glm(A~B+C+D+E,family = binomial(link = "logit"),data=tre,na.action=na.omit)
runs fine
glm(A~B+C+D+F,family = binomial(link = "logit"),data=tre,na.action=na.omit)
runs fine
glm(A~E+F,family = binomial(link = "logit"),data=tre,na.action=na.omit)
Error in `contrasts<-`(`*tmp*`, value = "contr.treatment") :
contrasts can be applied only to factors with 2 or more levels
Why is this? Could it be due to collinearity between the two?
Regards,
//M
More information about the R-help
mailing list