I am trying to create a Sankey chart in a Jupyter notebook, basing my code on the first example shown here.
I ended up with this, which I can run without getting any
I can get the correct display with jupyter notebook server (without any additional options), but get a blank block
with jupyter lab server. Related version info:
$ jupyter lab --version
0.35.5
$ jupyter notebook --version
5.7.8
$ python -c "import plotly; print(plotly.__version__)"
3.10.0
So for those who are using JupyterLab, to properly display the offline plotly graphs in JupyterLab, we need to install the plotly-extension with following commands (following is excerpted from a related answer):
$ jupyter labextension install @jupyterlab/plotly-extension
$ jupyter labextension list
$ jupyter lab build