问题
在MINGW中用python -m pip install matplotlib 命令安装matplotlib后显示pystan没有安装成功,因此继续用python -m pip install pystan去安装pystan,结果报错信息为
ERROR:Could not find a version that satisfies the requirement httpstan<4.5,>=4.4 (from pystan>=2.14->fbprophet) (from versions: 0.1.0, 0.1.1, 0.2.3, 0.2.5, 0.3.0, 0.3.1, 0.4.0, 0.5.0, 0.6.0, 0.7.2, 0.7.3, 0.7.5, 0.7.6, 0.8.0, 0.9.0, 0.10.1, 1.0.0)
ERROR: No matching distribution found for httpstan<4.5,>=4.4 (from pystan>=2.14->fbprophet)。
详细信息如下图所示:
解决方法
根据参考资料1中的回答找到了解决该问题的方法,用pip install pystan~=2.14即可安装成功pystan-2.19, 如下图所示,pip源的url采用的是豆瓣镜像。
为了避免SSL报错,特意加上了--trusted-host参数。
注意,这里如果将~= 换成>=也不能安装成功。
参考资料:
2.https://github.com/facebook/prophet/issues/17#issuecomment-808769442