Creating animated and interactive plots

There are a few tools for interactive plots that one may choose from, such as Bokeh, Plotly, and VisPy.

Bokeh allows you to plot matplotlib objects via JavaScript, which enables the interactive part easily. For instance, if one needs a map plot that is interactive, Bokeh can be used. Bokeh uses JavaScript and enables D3.js style plots and targets the visualization via modern web browsers. Bokeh delivers good performance over a large dataset. You can easily install bokeh either via conda or pip, as shown in the following code:

conda install bokeh
   OR
pip install bokeh
import collections from bokeh.sampledata import us_counties, unemployment from bokeh.plotting import figure, show, output_file from bokeh.models ...

Get Python: Data Analytics and Visualization now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.