Matplotlib 1.3.1 to 1.4.2 in ubuntu 14.04

Un article de Informaticiens département des sciences de la Terre et l'atmosphère
Version depuis le 16 d'octobre 2015 à 12:30 par Toupin (Discuter | changes)
(diff) ←Version avant | Version courante (diff) | Version après→ (diff)
Aller à: navigation, charcher

UPGRADING FROM MATPLOTLIB 1.3.1 TO 1.4.2 IN UBUNTU 14.04

The preferred method for installing matplotlib is to use the default package manager for you system. In Ubuntu the default package manager is APT and can be used to install packages in the following way:
sudo apt-get install python-matplotlib
This method however failed to upgrade to the newest version so I attempted to upgrade using the python package manager (PIP)
sudo pip install --upgrade matplotlib
This also failed, finally after some digging I came across this page in which they confirm that a bug is the reason PIP is failing and that a workaround can be found by installing libreetype6-dev
# Install libfreetype6-dev
sudo apt-get install libfreetype6-dev
# Upgrade to matplotlib 1.4 using PIP
sudo pip install --upgrade matplotlib