PyCharm 2019.1 Jupyter support doesn't seem to render plotly plots

Answered
#%%
import pandas as pd
import plotly_express as px
from plotly.offline import download_plotlyjs, init_notebook_mode, plot, iplot
init_notebook_mode(connected=True)
import numpy as np

#%%
pd.show_versions()

#%%
df = pd.DataFrame(np.random.randn(1000, 2), columns=['a', 'b'])

#%%
df.head()

#%%
px.scatter(df, x='a', y='b')
# yields nothing in PyCharm interface, but works in regular jupyter web interface:

PyCharm interface shows empty output:



Works in regular Jupyter interface:
3
1 comment

There is a known issue with Plotly and Jupyter Notebook in PyCharm https://youtrack.jetbrains.com/issue/PY-18662, please vote for it and follow for updates.

0

Please sign in to leave a comment.