当指定颜色/填充/组时,stat_compare_means不适用于“ ref.group”

将数据按颜色/填充/组分组时,如果指定了ref.group,则stat_compare_means不起作用。

敌人的示例,此代码有效:

ggbarplot(ToothGrowth,x = "dose",y = "len",add = "mean_se",color = "supp",palette = "jco",position = position_dodge(0.8))+
    stat_compare_means(aes(group = supp),label = "p.signif",label.y = 29)
ggline(ToothGrowth,palette = "jco")+
    stat_compare_means(aes(group = supp),label.y = c(16,25,29))

但这不是:

ggbarplot(ToothGrowth,29),ref.group='OJ')
Warning message:
Computation failed in `stat_compare_means()`:
missing value where TRUE/FALSE needed 
a436084592 回答:当指定颜色/填充/组时,stat_compare_means不适用于“ ref.group”

暂时没有好的解决方案,如果你有好的解决方案,请发邮件至:iooj@foxmail.com
本文链接:https://www.f2er.com/2875681.html

大家都在问