微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

如何在 R 中更改 effect_plot (jtools) 的间隔颜色?

如何解决如何在 R 中更改 effect_plot (jtools) 的间隔颜色?

我为我的 R 分析 运行了一套配色方案,并希望将其集成到我的多元非线性回归的可视化中。我正在使用 effect_plot() 包中的 jtools,因为它是我发现的最方便的功能

到目前为止,我尝试添加 geom_smooth(se = Light_Blue)geom_ribbon(fill = Light_Blue),同时将 interval = FALSE 设置在effect_plot(),不成功。

期待任何帮助!

### Visualization of regression

effect_plot(model2,pred = novelty,centered = FALSE,interval = FALSE,colors = Dark_Blue)+
  ggtitle("Title") +
  geom_line(size = 1) +
  ylim(0,5)+
  labs(x = "x.text",y= "y.text") +
  theme_minimal() +
  theme(text=element_text(family="Times",face="bold",size=14),plot.title = element_text(hjust = 0.5),axis.title.y = element_text(margin = margin(t = 0,r = 20,b = 0,l = 0)),axis.title.x = element_text(margin = margin(t = 20,r = 0,)
    
### Color Codes for Plots
    
    Dark_Blue     = "#150563"
    Light_Blue    = "#8ecff5"
    Grey          = "#c2cacf"

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。