无法在IPython 6.5.0控制台(Spyder)中导入熊猫

时间:2018-10-02 14:51:55

标签: python-3.x pandas kernel ipython spyder

安装熊猫后,可以如下所示在cmd中导入

C:\Users\me\Desktop\Django_Project>python
Python 3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:59:51) [MSC v.1914 64 bit    
(AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import pandas
>>>

但是在IPython 6.5.0控制台中的Spyder中导入熊猫时,出现以下错误:

Python 3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:06:47) [MSC v.1914 32 bit (Intel)]
Type "copyright", "credits" or "license" for more information.

IPython 6.5.0 -- An enhanced Interactive Python.
c:\program files (x86)\python37-32\lib\site-packages\ipykernel\parentpoller.py:116: UserWarning: Parent poll failed.  If the frontend dies,
                the kernel may be left running.  Please let us know
                about your system (bitness, Python, etc.) at
                ipython-dev@scipy.org
  ipython-dev@scipy.org""")

In [1] : import pandas
Traceback (most recent call last):

  File "<ipython-input-1-38d4b0363d82>", line 1, in <module>
    import pandas

ModuleNotFoundError: No module named 'pandas'

In [2] :

注意:我已经在“ C:\ Users \ me \ AppData \ Local \ Programs \ Python \ Python37 \”路径中安装了python,环境变量设置为“ C:\ Users \ me \ AppData \ Local \ Programs \ Python \ Python37;“

然后我使用PIP安装了熊猫

请提出解决此问题的解决方案。我尝试将pandas软件包重新安装近6-7次。

1 个答案:

答案 0 :(得分:0)

我认为您应该通过在Windows搜索栏中搜索anaconda命令提示符来打开它。现在在此处写“ conda install -c anaconda pandas”,然后重试以运行程序