我想要将行为空的列中的值替换为我的列tech.role的"NO“。
mental.health$tech.role <- as.factor(mental.health$tech.role)
levels(mental.health$tech.role)<-c("No","Yes")
Error in `levels<-.factor`(`*tmp*`, value = c("No", "Yes")) :
number of levels differs这就是我得到的错误
发布于 2019-06-11 02:08:22
mental.health$tech.role[is.na(mental.health$tech.role)] <- 'NO'https://stackoverflow.com/questions/56531331
复制相似问题