我正在使用gganimate
创建一些要插入到报告中的 .gif 文件。我可以保存文件并很好地查看它们,但是,我发现显示的尺寸很小:480x480。有没有办法调整它 - 也许沿着height
和width
论点ggsave()
?
我可以放大,但这对质量的影响很差,并且对于我的用例来说相当难以阅读。
这是一些示例代码:
gplot <-
ggplot(gapminder,
aes(x = gdpPercap, y = lifeExp, colour = continent,
size = pop,
frame = year)) +
geom_point(alpha = 0.6) +
scale_x_log10()
gganimate(gplot, "test.gif")
以下是此代码的输出。