关于Ubuntu 12.04:无法将Matplotlib升级到1.3.1

can not upgrade matplotlib to 1.3.1

注释sudo apt-get install python-matplotlib正在安装1.1.1rc版本,而不是最新版本。我需要使用matplotlib 1.3.1填充曲线之间的阴影。没有升级命令导致成功。在网络上没有任何帮助,可以成功运行。请帮忙。 Ubuntu版本12.04。


ubuntu存储库不包含最新版本。您可以使用pip安装最新版本。

如果尚未安装pip,请使用sudo apt-get install pip进行安装。

然后使用

1
sudo pip install --upgrade matplotlib

将matplotlib升级到最新版本。

以防万一,您会收到类似

的错误消息

1
2
Running setup.py egg_info for package matplotlib
The required version of distribute (>=0.6.28) is not available, and can't be installed while this script is running. Please install a more recent version first, using 'easy_install -U distribute'

执行

1
easy_install -U distribute

,然后再次尝试sudo pip install --upgrade matplotlib