AndrewRook / ptplot

Easily make interactive plots of player-tracking data
GNU General Public License v3.0
11 stars 3 forks source link

Figure out how to hook up animations by setting tags on bokeh figures #21

Open AndrewRook opened 3 years ago

AndrewRook commented 3 years ago

In order to provide hooks between the figures and the animation widgets each layer.draw method can optionally return a closure which can then be called to connect the animation.

This is super clunky and unintuitive.

I think a better way would be to attach any needed animation attributes/methods as tags on the bokeh figure, then iterate over the figures looking for any that have the relevant tags if an animation is set.