Questions tagged [gganimate]

gganimate is a package for R that allows to produce animated graphics with ggplot2. It is based on the animation package.

gganimate is a package for R that allows to produce animated graphics with ggplot2. It is based on the animation package.

Repositories:

549 questions
0
votes
1 answer

How to animate 3D scatter plot by adding each point at a time in R or MATLAB

I have a set of 3D coordinates here. The data has 52170 rows and 4 columns. Each row represent one point. The first column is point index number, increasing from 1 to 52170. The second to fourth columns are coordinates for x, y, and z axis,…
Patrick
  • 1,057
  • 9
  • 23
0
votes
0 answers

How modify the gif´s title with transition_manual on gganimate?

I want change the title´s name with the names of the murder$mes, I try with transition_time but it is not works. It´s only works with transition_manual This is the code (reproducible) library(ggmap) library(sp) murder <- subset(crime, offense ==…
0
votes
1 answer

geom_label_repel not appearing correctly in animation

With a basketball dataset, I'm trying to build an animation of a line graph with a metric called EPV on y-axis and time on x-axis. I can get this to work, but now I'd like to add text labels at specific time points where any event occurs. An event…
user8248672
0
votes
0 answers

What issues does gganimate have with layer?

I am following a basic tutorial on gganimate: p <- ggplot(iris, aes(x = Petal.Width, y = Petal.Length)) + geom_point() When I try the snippet of code below: p + transition_states(Species, transition_length = 2, …
Dasr
  • 777
  • 6
  • 16
0
votes
0 answers

R - Animated Graphs (gganimate) - Can I order the Y axis?

I need to do a animated graph which shows top ten UF. I'm trying, but the graph are showing top 14 and they are not in order. There will be 8 graphs (one for each CBO) which shows de amount of CBO by UF as time goes by. UF must be in order, from…
RxT
  • 486
  • 7
  • 17
0
votes
0 answers

How can I adjust the axis-x dynamically only if the values overflow a preset value or the chart in R?

I tried to use view_follow() with no success... I want to display the chart with a smaller scale and change the axis-x according the data... How can I adjust the axis-x dynamically only if the values overflow a preset value or the…
Bnknews
  • 11
  • 5
0
votes
1 answer

is there any way to create an animation (gganimate) with ranges as transition times?

Is there any way to make gganimate work for transition times that are ranges of years? In my data I have three time points, two of which are ranges as shown below. data: Year rate group 2012-2014 7 Other CT, White 2015-2017 11 Other…
0
votes
1 answer

Tween circle to star with xy data frame using library(tweenr)

I can morph shapes represented as simple feature geometry ok. I need to do the same thing with the shapes stored as a standard x,y dataframe. Why does the x,y dataframe method not work for me? Using Simple Features - Works OK …
ixodid
  • 2,180
  • 1
  • 19
  • 46
0
votes
1 answer

Why is animation plot smaller than static plot?

The code below morphs a star into a circle. If I just plot the the star the size is great. ggplot(star1) + geom_sf(aes(geometry = geometry)) However, the animation ends up being smaller: What do I do to have the animation the same size as the…
ixodid
  • 2,180
  • 1
  • 19
  • 46
0
votes
1 answer

Display animated plot using gganimate in knitr Markdown for ioslides presentation: root directory

I want to embed a plot produced with ggplot and gganimate into a slideshow using knitr. I can produce animation when data and .Rmd file in same folder. Here is a reproducible example for animation. ```{r setup,…
David
  • 3
  • 1
  • 4
0
votes
1 answer

Non-smooth colour transition of shape with tweenr/transformr

I wish to smoothly morph the colour of the 5 pointed star to the colour of the ten pointed star. Currently, the color transition is abrupt, not smooth. I think I am using geom_sf(aes(fill = ...)) incorrectly but am unsure how to proceed. Here is…
ixodid
  • 2,180
  • 1
  • 19
  • 46
0
votes
0 answers

Can't call gganimate function

I installed gganimate packages from CRAN and run the sample codes provided: library(ggplot2) library(gganimate) library(gapminder) ggplot(gapminder, aes(gdpPercap, lifeExp, size = pop, colour = country)) + geom_point(alpha = 0.7, show.legend =…
user2236600
  • 157
  • 10
0
votes
1 answer

gganimate showing transition along some objects

I m trying to create animation to show transition along some nodes. I want to show point moving from SRC to TGT with transition change in intensity my df is like this below. > df node intensity Lon Lat 1 SRC 0.90 40 60 2 TGT 0.89 …
aprilian
  • 621
  • 3
  • 17
0
votes
0 answers

Duplicate prints with gganimate

I m trying to create a animation with ggplot and gganimate combination but i m getting prints left on my graph.The dots are not moving properly. I appreciate any help. My code ggplot(newfile, aes(Date, TotalReturn, color = Investor)) + …
gurtej
  • 13
  • 5
0
votes
1 answer

Issue creating animation with Date vs Value and Investors with gganimate

I m trying to animate geom_line graph with below mentioned data : quarter Total.Return Investor 2009-03-30 4 A 2009-03-30 5 B 2009-06-30 7 A 2009-06-30 10 B 2009-09-30 12 A 2009-09-30 …
gurtej
  • 13
  • 5