Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test jupyterlab-plotly, jupyterlab-dash and jupyter-matplotlib #104

Closed
ca-scribner opened this issue Sep 4, 2020 · 4 comments
Closed

Test jupyterlab-plotly, jupyterlab-dash and jupyter-matplotlib #104

ca-scribner opened this issue Sep 4, 2020 · 4 comments
Assignees
Labels

Comments

@ca-scribner
Copy link
Contributor

ca-scribner commented Sep 4, 2020

Do they work? jupyter-matplotlib gave me these errors:

matplotlib notebook
matplotlib.pyplot as plt
plt.plot([[0,0], [1,1]], label='line')
plt.show()

Make sure they do, and while doing that build demo notebooks that can be added to jupyter-notebooks repo so we have both test cases and demos for users

@ca-scribner
Copy link
Contributor Author

the matplotlib extension is also installed twice (once by us, and once upstream). Remove the second one?

@ca-scribner
Copy link
Contributor Author

jupyterlab-dash has been deprecated in place of jupyter-dash. Update to the newer one

@Jose-Matsuda
Copy link
Contributor

Confirming that I get the "IPython is not defined" with %matplotlib notebook
From what I understand we should use %matplotlib widget instead. See matplotlib jupyter-notebooks or the matplotlib ipympl github proj

So your snippet of code became

%matplotlib widget 
import matplotlib.pyplot as plt
import numpy as np
plt.plot([[0,0], [1,1]], label='line')
plt.show()

Removed the extra installation of jupyter-matplotlib in the minimal-notebook cpu and tested in the Python 3 notebook successfully. Graph was interact-able (moused over graph and X+Y co-ords appeared below as opposed to a normal graph created by just running the code sans %matplotlib widget)
Saved+downloaded the notebook containing the code above and the resulting graph.

Still TODO:

  • Update jupyterlab-dash to jupyter-dash.
  • Test jupyter-dash
  • Test jupyter-plotly

@Jose-Matsuda
Copy link
Contributor

jupyter-plotly works with some examples from plotly.com basic charts the following is from bar charts

import plotly.express as px
data_canada = px.data.gapminder().query("country == 'Canada'")
fig = px.bar(data_canada, x='year', y='pop')
fig.show()

jupyterlab-dash
Example(s) from the jupyterlab-dash git page do not produce expected output.
Does not appear in installed extensions.


TLDR;
jupyter-matplotlib: works, removed the duplicate installation still worked, have the ipynb file.
jupyter-plotly: works, have the ipynb file.
jupyterlab-dash: no bueno

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants