R/ggplot-convert.R
convert_ggplot_to_manim.Rd
Converts a ggplot2 plot object into a manimR scene that can be animated.
convert_ggplot_to_manim( plot, name = "ggplot_animation", animate_build = TRUE, duration = 2 )
A ggplot2 plot object
Scene name
Whether to animate the plot being built
Duration for build animation
A Scene object
if (FALSE) { # \dontrun{ library(ggplot2) p <- ggplot(mtcars, aes(mpg, wt)) + geom_point() convert_ggplot_to_manim(p) %>% render() } # }