Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to efficiently animate a Graphviz graph?

I would like to animate a Graphviz generated graph, changing the node labels and the node and edge colors.

I was creating the graphs using this Python interface for Graphviz. The only way to do that seems to be to create every image independently (although the changes between frames would be very small) and join all the images into an animation, as explained here.

Is there a more efficient way to create the animation, avoiding the creation of all these images independently?

like image 420
Mario Román Avatar asked Nov 02 '14 11:11

Mario Román


2 Answers

There is also d3-graphviz, which takes a full dot graph description per animation step, converts it into an SVG, and then uses JavaScript to convert one graph into the other, and to inject animation.

You can see an example here.

like image 69
hoijui Avatar answered Nov 18 '22 07:11

hoijui


There is a python package (GraphvizAnim) to do so. Being in alpha only, but non the less looking quite decent.

like image 40
Paul Würtz Avatar answered Nov 18 '22 09:11

Paul Würtz