ggplot2 生成的切片图
我想知道是否可以将图形分别切片为使用 ggsave 生成的 .png 文件。如果我不想使用默认的图例或标题并将其设置为 FALSE,则会留下大量空白。那么有没有一种 R 方法可以将文件剪切到图形本身上方和下方几个像素呢?
提前谢谢!
I wonder if it's possible to slice a graph respectively a .png file generated with ggsave. If I do not want to use the default legend ort title and set it to FALSE it leaves me with a lot of white space. So is there an R way to just cut the file several pixels above and below the graph itself?
Thx in advance!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以更改
plot.margin
,例如,从版本 0.9.2 开始,
opts
已变为 替换为主题
:You could change the
plot.margin
, e.g.Since version 0.9.2
opts
has been replaced bytheme
: