我第一次使用gganimate,我只是尝试从github运行示例代码,即:
library(ggplot2)
library(gganimate)
ggplot(mtcars, aes(factor(cyl), mpg)) +
geom_boxplot() +
# Here comes the gganimate code
transition_states(
gear,
transition_length = 2,
state_length = 1
) +
enter_fade() +
exit_shrink() +
ease_aes('sine-in-out')但是当我试图运行它时,我会发现一个错误。(这与我尝试使用gganimate做任何事情的错误相同。)是这样的:
Error in gifski_first_error <<- FALSE :
cannot change value of locked binding for
'gifski_first_error'谢谢!
发布于 2018-12-12 09:12:15
我也有过类似的问题。尝试安装"gifski“和"png”包,然后运行提供的代码。
发生此错误是因为gifski_renderer()是当前的默认呈现程序。
欲了解更多信息,请访问此处:https://github.com/thomasp85/gganimate/commit/8248357809860c0e1a90eaf1f2ac1cdee1a95a64
https://stackoverflow.com/questions/53734704
复制相似问题