Kyso's Jupyter Renderer
This article lays out some important points to know about how Jupyter notebooks are rendered on Kyso.

Images

We don't support image links with spaces in the name. So if you link an image in a markdown cell do it like this:
1
![alt text](image_name.png)
Copied!
and don't do it like this:
1
![alt text](image name.png)
Copied!

IPyWidgets

While interactive javascript plots like Plotly and Bokeh do work (as well as associated client side widgets), IPyWidgets won't work as they require a running kernel - which Kyso does not provide (yet!!).

Bokeh Plots on Kyso

To make bokeh plots work inside Jupyter and render on Kyso, we will save the plot to a virtual html file and show it:
1
from bokeh.plotting import figure, output_file, save
2
from IPython.display import IFrame
3
from IPython.core.display import display, HTML
4
import tempfile
5
6
def bokeh_show(plot):
7
tmp_output_filename = tempfile.NamedTemporaryFile(suffix='.html').name
8
output_file(tmp_output_filename)
9
save(plot)
10
11
f = open(tmp_output_filename, "r")
12
display(HTML(f.read()))
Copied!
Then we can use this function bokeh_show to show any plots we create:
1
p = figure(title="Bokeh test", plot_width=300, plot_height=300)
2
p.circle([1, 2], [3, 4])
3
4
bokeh_show(p)
Copied!

Other Resources

Be sure to check out our guide on writing a good data science report for the intended audience and ensure your insights actually drive real action around the business: