Bokeh inside Google Colab

2019-05-24 13:25发布

问题:

Matplotlib doesn't give me the visualisation I want

I like the interactive features of Bokeh and I would like to see if someone was able to get it running inside Google Colab?

I installed the library (from the notebook itself) and it showed the installation is successful

!pip install bokeh

but when I use it. It doesn't show anything (not even an error). Just blank output. When I check chrome's Javascript console, I see the follwoing

Bokeh: ERROR: Unable to run BokehJS code because BokehJS library is missing

回答1:

There's a Bokeh sample in the charts example notebook.

I suspect the important bit you'll need to add is:

from bokeh.io import output_notebook
output_notebook()

And most importantly output_notebook() must be called inside the same cell