我想用 cplot() 绘制我的 logit 模型 (mod7) 的边际效应,但我不知道如何解决这个错误
这里的代码:
mod7 <- glm(Crosssectionunique$ACQYes ~ Crosssectionunique$management + controls + Crosssectionunique$emp_firm)
mod8 <- glm(Crosssectionunique$ACQYes3 ~ Crosssectionunique$management + controls + Crosssectionunique$emp_firm)
summary(mod7)
install.packages("margins")
library("margins")
cplot(mod7, x = "Crosssectionunique$management", se.type = "shade")
Error in names(classes) <- clean_terms(names(classes)) :
'names' attribute [3] must be the same length as the vector [2]
有什么建议么 ?