Simple script-based plotting example doesn't display within ipython 1.1.0 notebook with bokeh 0.3
See original GitHub issueUsing bokeh 0.3 with ipython 1.1.0, the initial example in the tutorial, i.e.,
from bokeh.plotting import *
output_notebook()
from numpy import *
x = linspace(-2*pi, 2*pi, 100)
y = cos(x)
output_file("cos.html")
line(x, y, color="red")
scatter(x, y, marker="square", color="blue")
returns something like
<bokeh.objects.Plot at 0x568a190>
but doesn’t display anything when run within the ipython notebook. Running the show() function will cause the plots to be displayed in a separate browser, though.
Issue Analytics
- State:
- Created 10 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Using with Jupyter — Bokeh 2.4.3 Documentation
Jupyter notebooks are computable documents often used for exploratory work, data analysis, teaching, and demonstration. A notebook is a series of input cells ......
Read more >The Notebook | Query and analyze data - Mode Support
Open an existing report or create a new report and run one or more SQL queries from the SQL Editor. Click New Notebook....
Read more >PyTplot's
Tplot Variables store all of the information needed to generate a plot. Parameters. • name – str Name of the tplot variable that...
Read more >bokeh.io
Does not change the current Document from curdoc(). ... the default output state to generate output in Jupyter/IPython notebook cells when show() is...
Read more >1 Jupyter / IPython notebook hints and tips
In [1]:. from IPython.display import display from IPython.display import Image from ... In this case the cells will simply not execute, with no...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
If you call
output_notebook()
, theshow
function has to display the plot inside the notebook. In the last release, this flow is working without any problems. BTW, since the last release (0.4.2), we had integrated a newbokeh magic
with let you activate a--show
mode to render the plots inline without calling theshow
function. For more information about the magic, check this notebook: http://nbviewer.ipython.org/github/ContinuumIO/bokeh/blob/master/extensions/BokehMagic.ipynb?create=1The output* functions are mutually exclusive in the sense that they manipulate a global “session”. There is no structural reason why there could not be two of these, but the design of the bokeh.plotting module was to simulate something akin to pylab-style plotting. In fact, the entire object graph constructed by the various plotting functions in bokeh.plotting can be stored into new session objects. In the examples/glyphs/ directory, there are examples that don’t use a session object except at the very end to actually output the plots.