![](/img/trans.png)
[英]"ModuleNotFoundError: No module named '…' even though module is installed
[英]ModuleNotFoundError: No module named 'panda' though panda is installed on my mac os
我已经在Mac OS上安装了anaconda。 但是,当我尝试导入熊猫库时,由于找不到熊猫模块而引发错误。
因此,当我再次尝试安装熊猫时。 它说熊猫已经安装在机器上
C27:python-programming jyoti.aditya$ pip install pandas
Requirement already satisfied: pandas in
/Users/aditya/anaconda3/lib/python3.7/site-packages (0.23.4)
Requirement already satisfied: python-dateutil>=2.5.0 in
/Users/aditya/anaconda3/lib/python3.7/site-packages (from pandas)
(2.7.3)
Requirement already satisfied: pytz>=2011k in
/Users/aditya/anaconda3/lib/python3.7/site-packages (from pandas)
(2018.5)
Requirement already satisfied: numpy>=1.9.0 in
/Users/aditya/anaconda3/lib/python3.7/site-packages (from pandas)
(1.15.1)
Requirement already satisfied: six>=1.5 in
/Users/aditya/anaconda3/lib/python3.7/site-packages (from python-
dateutil>=2.5.0->pandas) (1.11.0)
但是当我尝试在我的python代码中导入Panda库时。 引发错误
C27:python-programming aditya$ python
Python 3.7.0 (default, Jun 28 2018, 07:39:16)
[Clang 4.0.1 (tags/RELEASE_401/final)] :: Anaconda, Inc. on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>
>>> import panda as pd
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'panda'
您已经通过pip
安装了pandas
,但是在尝试导入它时,您错过了pandas
结尾处的s。
import pandas as pd
将工作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.