Error in `contrasts' Error
问题 I have trained a model and I am attempting to use the predict function but it returns the following error. Error in contrasts<- ( *tmp* , value = contr.funs[1 + isOF[nn]]) : contrasts can be applied only to factors with 2 or more levels There are several questions in SO and CrossValidated about this, and from what I interpret this error to be, is one factor in my model has only one level. This is a pretty simple model, with one continuous variable (driveTime) and one factor variable which has