Jane Mänd
Jane Mänd

Reputation: 187

Can I make Jupyter Notebook interactive in Github?

Using the following code, I created a slider widget in my local machine Jupyter Notebook.

import ipywidgets as widgets
widgets.IntSlider(
    min=0,
    max=10,
    step=1,
    description='Slider:',
    value=3
)

enter image description here

After uploading the project into Github environment, the graphical interface was lost and instead the message 'IntSlider(value=3, description='Slider:', max=10)' was generated. So, is it possible at all to make Jupyter Notebook interactive in Github? What libraries/tools would be the best choice for that?

Upvotes: 4

Views: 2284

Answers (1)

Donald S
Donald S

Reputation: 1753

I don't think this can be done from github. I found this on the github website:

"When you add Jupyter Notebook or IPython Notebook files with a .ipynb extension on GitHub, they will render as static HTML files in your repository."

"The interactive features of the notebook, such as custom JavaScript plots, will not work in your repository on GitHub. For an example, see Linking and Interactions.ipynb."

The main purpose for github is to store and share code and for version control.

When I want someone to interact with my Jupyter notebooks, I like to use Kaggle for this. I can upload and run a Jupyter notebook interactively, save versions, etc. No need to enter a competition, just save your notebook as a Kaggle "kernel". For large datasets, I use Google Colab (free version).

Some other ideas:

https://www.dataschool.io/cloud-services-for-jupyter-notebook/

Upvotes: 2

Related Questions