繁体   English   中英

无法在 PyCharm 中安装 Pandas

[英]Can't install Pandas in PyCharm

我是编程的新手。 为了稍微开始,我尝试使用pip install Pandas在 PyCharm 中pip install Pandas 当我尝试通过终端或设置安装它时,我收到以下信息:

  Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', OSError(0, 'Error'))': /simple/pandas/
  Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', OSError(0, 'Error'))': /simple/pandas/
  Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', OSError(0, 'Error'))': /simple/pandas/
  Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ProtocolError('Connection aborted.', OSError(0, 'Error'))': /simple/pandas/
  Could not find a version that satisfies the requirement pandas (from versions: )
No matching distribution found for pandas

由于我已经安装了 Pandas 以在 Jypiter Notebook 中使用,因此在输入pip install pandas时,mac 终端会为我提供以下信息:

Requirement already satisfied: pandas in ./opt/anaconda3/lib/python3.7/site-packages (0.25.1)
Requirement already satisfied: pytz>=2017.2 in ./opt/anaconda3/lib/python3.7/site-packages (from pandas) (2019.3)
Requirement already satisfied: python-dateutil>=2.6.1 in ./opt/anaconda3/lib/python3.7/site-packages (from pandas) (2.8.0)
Requirement already satisfied: numpy>=1.13.3 in ./opt/anaconda3/lib/python3.7/site-packages (from pandas) (1.17.2)
Requirement already satisfied: six>=1.5 in ./opt/anaconda3/lib/python3.7/site-packages (from python-dateutil>=2.6.1->pandas) (1.12.0)
Could not fetch URL https://pypi.org/simple/pip/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/pip/ (Caused by SSLError(SSLError("bad handshake: SysCallError(-1, 'Unexpected EOF')"))) - skipping

虽然它看起来像 Pandas 已经安装在计算机上(那里的 anaconda3 给我带来了麻烦),但它不适用于 PyCharm。 我在 PyCharm 2019.3 中使用 Python 3.8,我的 pip 版本是 19.0.3

我很高兴得到任何帮助,非常感谢!

请试试这个:Pycharm(在你的左上角)>首选项>项目>项目解释器>+(加号)(表格底部)>输入pandas>下载

恕我直言,您需要使用homebrew安装openssl

brew install openssl

您可以检查这个: 尝试从终端安装 pip 时出错

不确定这是否有帮助,但我通常在 pycharm 中编写一个小的 python 脚本,它导入熊猫,然后在脚本窗口中它会说“熊猫未安装”,然后我只需单击它并为我安装库。

我收到了同样的错误信息。 我试过一切。 事实证明,Pycharm 只有专业版的 pandas 和 numpy。 请检查您是否使用免费社区版本,它不支持 pandas 或 numpy

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM