删除ggplot中传说大纲的方法

发布于 2025-01-21 21:46:43 字数 711 浏览 2 评论 0原文

在R中,我的图将显示传奇标题为“深度” 当我添加指南以更改标题以资本化深度时,它会在传说中的每个层面上增加黑色边框。我想使用另一种方法来重命名传奇标题,并保持关卡的渐变外观,或删除黑色轮廓。

ggraph(df.graph, layout = 'partition') + 
  geom_node_tile(aes(fill = depth)) +
  guides(fill=guide_legend(title="Depth", reverse = TRUE)) +
  theme(panel.background = element_rect(fill = NA, color = NA)) 

我喜欢深度大写,但不喜欢黑色边界

我喜欢这里的梯度,光滑的颜色过渡,但不喜欢小写的深度

In R my graph would show legend title as "depth"
When I added guides to change title to capitalize Depth it adds black border around each level in the legend. I'd like to either use another method to rename legend title and keep the gradient look of the levels or remove the black outline.

ggraph(df.graph, layout = 'partition') + 
  geom_node_tile(aes(fill = depth)) +
  guides(fill=guide_legend(title="Depth", reverse = TRUE)) +
  theme(panel.background = element_rect(fill = NA, color = NA)) 

I like Depth capitalized but don't like the black border
remove black outline

I like the gradient, smooth color transition here but not lowercase depth
enter image description here

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文