Plotly Animation with scattergl

Hello,

i am trying to animate a scatter plot with shiny and plotly.
For performance reasons I am using WebGL to render the plot ( by using plotlys 'scattergl' type).
However, when starting the animation the trace just disappears. When using SVG to render the plot, the animation works just fine.

This seems odd, as animations work fine for scatter3d plots which also use WebGL.

See below for a reproducible example.

library(gapminder)
plot_ly(gapminder,x  = ~ gdpPercap, y = ~lifeExp, mode = "markers", type = "scattergl",text = ~country,frame = ~year)

Has anyone experienced the same thing and knows a workaround?

Thank you.

The same was discussed here. You may use pointcloud as an alternative:

library(plotly)
library(gapminder)
plot_ly(gapminder, x  = ~ gdpPercap, y = ~lifeExp, type = "pointcloud", text = ~country, frame = ~year)

This topic was automatically closed 54 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.