pycharm导入pandas时出现找不到模块的问题
其实这个降低pandas的版本就行,步骤如下:
1、找到所有的pandas版本
// An highlighted block
pip install pandas==6666666(很大就行,当然我这个也可以)
C:\Users\Huawei>pip install pandas==6666666
ERROR: Could not find a version that satisfies the requirement pandas==6666666 (from versions: 0.1, 0.2b0, 0.2b1, 0.2, 0.3.0b0, 0.3.0b2, 0.3.0, 0.4.0, 0.4.1, 0.4.2, 0.4.3, 0.5.0, 0.6.0, 0.6.1, 0.7.0, 0.7.1, 0.7.2, 0.7.3, 0.8.0rc1, 0.8.0, 0.8.1, 0.9.0, 0.9.1, 0.10.0, 0.10.1, 0.11.0, 0.12.0, 0.13.0, 0.13.1, 0.14.0, 0.14.1, 0.15.0, 0.15.1, 0.15.2, 0.16.0, 0.16.1, 0.16.2, 0.17.0, 0.17.1, 0.18.0, 0.18.1, 0.19.0, 0.19.1, 0.19.2, 0.20.0, 0.20.1, 0.20.2, 0.20.3, 0.21.0, 0.21.1, 0.22.0, 0.23.0, 0.23.1, 0.23.2, 0.23.3, 0.23.4, 0.24.0, 0.24.1, 0.24.2, 0.25.0, 0.25.1, 0.25.2, 0.25.3, 1.0.0, 1.0.1, 1.0.2, 1.0.3, 1.0.4, 1.0.5, 1.1.0, 1.1.1, 1.1.2, 1.1.3, 1.1.4, 1.1.5, 1.2.0, 1.2.1, 1.2.2, 1.2.3, 1.2.4, 1.2.5, 1.3.0, 1.3.1)
ERROR: No matching distribution found for pandas==6666666
2、安装指定的pandas(找到低版本的安装(要提前卸载之前安装的pandas))
// An highlighted block
pip install pandas==1.0.3(要安装的版本号,可以自定,我的2017的pycharm可以)
3、验证是否安装成功
这个可以在pycharm里验证,当然也可以在电脑上找到cmd,
// An highlighted block
Microsoft Windows [版本 10.0.19041.1110]
(c) Microsoft Corporation。保留所有权利。
C:\Users\Huawei>python
Python 3.8.2 (tags/v3.8.2:7b3ab59, Feb 25 2020, 23:03:10) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import pandas
>>>
这样就行了。