============== Plotly Example ============== Thebe can display output from plotly.py_. .. _plotly.py: https://github.com/plotly/plotly.py Setup ===== Be sure to load require.js before any of your thebe activation code so that the Jupyter widgets can function: .. code-block:: html Configure thebe and load it: .. code-block:: html Create a button to activate thebe: .. code-block:: html Now add code cells between these HTML tags: .. code-block:: html


Example
=======

.. raw:: html

   
   
   

Press the "Activate" button below to connect to a Jupyter server:

.. raw:: html

   
   

Here is a distribution plot example from https://plotly.com/python/distplot/
(MIT License):

.. raw:: html

   
   import plotly.express as px
   df = px.data.tips()
   fig = px.histogram(df, x="total_bill", y="tip", color="sex", marginal="rug",
                      hover_data=df.columns)
   fig.show()