gganimate extends the grammar of graphics as implemented by ggplot2 to include the description of animation. It does this by providing a range of new grammar classes that can be added to the plot object in order to customize how it should change with time. Here we take a simple boxplot of fuel consumption as a function of cylinders and let it transition between the number of gears available in the cars. As this is a discrete split (gear being best described as an ordered factor) we use transition_states and provide a relative length to use for transition and state view. As not all combinations of data are present there are states missing a box. We define that when a box appears it should fade into view, whereas it should shrink away when it disappears. Lastly, we decide to use a sinusoidal easing for all our aesthetics (here, only y is changing) gganimate is available on CRAN and can be installed with install.packages('gganimate').

Features

  • gganimate mimics the way ggplot2 renders its output
  • Under the hood, the animate() function is called which renders the frame and passes the frames to a renderer functions
  • gif is a fantastic format for animations due to its wide support
  • Further there’s support for rendering to sprite sheets if that is your vice
  • Video output are automatically embedded in RMarkdown documents
  • This is the second iteration of the gganimate package

Project Samples

Project Activity

See All Activity >

Follow gganimate

gganimate Web Site

Other Useful Business Software
AI-generated apps that pass security review Icon
AI-generated apps that pass security review

Stop waiting on engineering. Build production-ready internal tools with AI—on your company data, in your cloud.

Retool lets you generate dashboards, admin panels, and workflows directly on your data. Type something like “Build me a revenue dashboard on my Stripe data” and get a working app with security, permissions, and compliance built in from day one. Whether on our cloud or self-hosted, create the internal software your team needs without compromising enterprise standards or control.
Try Retool free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of gganimate!

Additional Project Details

Programming Language

R

Related Categories

R Graphics Software, R Data Visualization Software

Registered

2022-07-13