Plotly:找不到 mimetype“application/vnd.plotly.v1+json”的渲染器

Jak*_*aur 8 python pandas plotly nbformat

环境:

  • 视觉代码
  • Jupyter 扩展 (v2022.9.1202862440)
  • 内核:Python 3.10.1 64位
  • pyplot 版本:5.10.0
  • Nb格式版本:5.7.0

发生了什么?

我正在尝试通过以下代码使用简单的箱线图plotly.express

#Basic vizualization
fig = px.box(dataset, y='Rh2')
fig.update_layout(
    height=1000
)
Run Code Online (Sandbox Code Playgroud)

第一个错误非常简单:ValueError: Mime type rendering requires nbformat>=4.2.0 but it is not installed我使用此答案解决了该错误。

第二个错误是我现在遇到的错误:

No renderer could be found for mimetype "application/vnd.plotly.v1+json", but one might be available on the Marketplace.
Run Code Online (Sandbox Code Playgroud)

我不知道在这里可以做什么 - 在互联网上没有提到这样的问题(至少我找不到任何)+市场空间也没有帮助!

提前致谢


编辑:

尝试添加:pio.renderers.default = "vscode"和其他各种内容,但它们不会导致错误,只是空白。

小智 8

尝试在 vscode 上安装Jupyter Notebook Renderers 扩展