2017-02-18 84 views
1

我目前正在嘗試使用基本的python-jupyter項目。jupyter ModuleNotFoundError:沒有名爲matplotlib的模塊

我被困在matplotlib中以下錯誤:

上jupyter錯誤截圖enter image description here

ModuleNotFoundError:無模塊命名爲 'matplotlib'

我嘗試更新,重新安裝matplotlib藏漢在conda和點子,但它仍然無法正常工作。

開心過每一個有建設性的反饋

+2

我敢打賭,你的'IPython中kernel'指向一個Python版本沒有'matplotlib'安裝。 – Abdou

+0

您需要在與筆記本的選定內核相關的環境中安裝模塊。在右上角,它應該指出你正在使用哪個內核。轉到「Kernel」 - >「Change Kernels」並嘗試選擇另一個,例如「根」。 – pylang

回答

0

檢查Python版本:

$python --version 

$python3 --version 

嘗試安裝 「matplotlib」 使用sudo:

對於Python 2.7版本

$sudo pip install matplotlib 

爲Python 3.x版本

$sudo pip3 install matplotlib 
相關問題