问题
How to export/save an animated bubble chart made with plotly? (For instance, the one was made following the link below) I would like to have it in a gift or some format with better resolution. Thank you in advance.
https://www.kaggle.com/aashita/guide-to-animated-bubble-charts-using-plotly
回答1:
There is no possibility to do this in plotly. Please use givemaker
and save every step in the animation as a single picture to later combine them to a gif. Follow this source. Further explanation on how to create animations is provided by plotly here.
The basic way to go would be to integrate this logic into the animation process of your plotly code:
import ImageSequence
import Image
import gifmaker
sequence = []
im = Image.open(....)
# im is your original image
frames = [frame.copy() for frame in ImageSequence.Iterator(im)]
# write GIF animation
fp = open("out.gif", "wb")
gifmaker.makedelta(fp, frames)
fp.close()
If you could provide your actual code, it would be possible to provide a more detailled answer to your question. :)
来源:https://stackoverflow.com/questions/55460434/how-to-export-save-an-animated-bubble-chart-made-with-plotly