我有以下虚拟模型
tran = make.tran("asin.sqrt", 100)
mod <- with(tran,
lm(linkfun(cty) ~ manufacturer + drv * linkfun(hwy), data = mpg))
但是,我无法获得方差分析表
joint_tests(mod)
Error in ratios && true.con && misc$tran %in% c("log", "log2", "log10", :
'length = 5' in coercion to 'logical(1)'
emmeans 确实识别了转换,详情请参阅 https://cran.r-project.org/web/packages/emmeans/vignettes/transformations.html。
emmeans(mod, ~ manufacturer, type = "response")
manufacturer response SE df lower.CL upper.CL
audi 15.0 0.258 214 14.4 15.5
chevrolet 16.1 0.240 214 15.7 16.6
dodge 16.2 0.216 214 15.8 16.6
ford 16.6 0.223 214 16.2 17.1
honda 17.4 0.390 214 16.7 18.2
hyundai 16.1 0.289 214 15.5 16.7
jeep 16.5 0.362 214 15.8 17.2
land rover 15.2 0.480 214 14.2 16.1
lincoln 15.7 0.634 214 14.4 16.9
mercury 16.0 0.479 214 15.1 17.0
nissan 16.8 0.289 214 16.2 17.3
pontiac 14.8 0.423 214 14.0 15.7
subaru 16.9 0.356 214 16.2 17.6
toyota 16.9 0.206 214 16.5 17.3
volkswagen 16.5 0.248 214 16.0 17.0
Results are averaged over the levels of: drv
Confidence level used: 0.95
Intervals are back-transformed from the asin(sqrt(mu/100)) scale
如何解决这个问题?感谢您过来。
这是一个已知的错误,已最近修复,以便在 emmeans 中进行未来更新。