Skip to content

Update INSTALL.rst. #11254

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 24, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
87 changes: 45 additions & 42 deletions INSTALL.rst
Original file line number Diff line number Diff line change
Expand Up @@ -38,23 +38,25 @@ macOS
To use the native OSX backend you will need :ref:`a framework build
<osxframework-faq>` build of Python.

Test Data
Test data
---------

The wheels (:file:`*.whl`) on the `PyPI download page
<https://pypi.python.org/pypi/matplotlib/>`_ do not contain test data
or example code.

If you want to try the many demos that come in the Matplotlib source
distribution, download the :file:`*.tar.gz` file and look in the
:file:`examples` subdirectory.

To run the test suite:

* extract the :file:`lib/matplotlib/tests` or
:file:`lib/mpl_toolkits/tests` directories from the source distribution;
* install test dependencies: `pytest <https://pypi.python.org/pypi/pytest>`_,
Pillow, MiKTeX, GhostScript, ffmpeg, avconv, ImageMagick, and `Inkscape
<https://inkscape.org/>`_;
* run ``pytest path\to\tests\directory``.
* extract the :file:`lib/matplotlib/tests` or :file:`lib/mpl_toolkits/tests`
directories from the source distribution;
* install test dependencies: `pytest <https://pypi.python.org/pypi/pytest>`_,
Pillow, MiKTeX, GhostScript, ffmpeg, avconv, ImageMagick, and `Inkscape
<https://inkscape.org/>`_;
* run ``python -mpytest``.

Third-party distributions of Matplotlib
=======================================
Expand All @@ -68,12 +70,12 @@ Scientific Python Distributions
<https://www.enthought.com/products/canopy/>`_ and `ActiveState
<https://www.activestate.com/activepython/downloads>`_ are excellent
choices that "just work" out of the box for Windows, macOS and common
Linux platforms. `WinPython <https://winpython.github.io/>`__ is an
option for windows users. All of these distributions include
Linux platforms. `WinPython <https://winpython.github.io/>`_ is an
option for Windows users. All of these distributions include
Matplotlib and *lots* of other useful (data) science tools.

Linux : using your package manager
----------------------------------
Linux: using your package manager
---------------------------------

If you are on Linux, you might prefer to use your package manager. Matplotlib
is packaged for almost every major Linux distribution.
Expand Down Expand Up @@ -133,57 +135,58 @@ Dependencies

Matplotlib requires the following dependencies:

* `Python <https://www.python.org/downloads/>`_ (>= 3.5)
* `NumPy <http://www.numpy.org>`_ (>= |minimum_numpy_version|)
* `setuptools <https://setuptools.readthedocs.io/en/latest/>`__
* `dateutil <https://pypi.python.org/pypi/python-dateutil>`_ (>= 2.1)
* `pyparsing <https://pyparsing.wikispaces.com/>`__
* `libpng <http://www.libpng.org>`__ (>= 1.2)
* `pytz <http://pytz.sourceforge.net/>`__
* FreeType (>= 2.3)
* `cycler <http://matplotlib.org/cycler/>`__ (>= 0.10.0)
* `kiwisolver <https://github.com/nucleic/kiwi>`__ (>= 1.0.0)
* `Python <https://www.python.org/downloads/>`_ (>= 3.5)
* `NumPy <http://www.numpy.org>`_ (>= |minimum_numpy_version|)
* `setuptools <https://setuptools.readthedocs.io/en/latest/>`_
* `dateutil <https://pypi.python.org/pypi/python-dateutil>`_ (>= 2.1)
* `pyparsing <https://pyparsing.wikispaces.com/>`_
* `libpng <http://www.libpng.org>`_ (>= 1.2)
* `pytz <http://pytz.sourceforge.net/>`_
* `FreeType <https://www.freetype.org/>`_ (>= 2.3)
* `cycler <http://matplotlib.org/cycler/>`_ (>= 0.10.0)
* `six <https://pypi.python.org/pypi/six>`_ (>= 1.10)
* `kiwisolver <https://github.com/nucleic/kiwi>`_ (>= 1.0.0)

Optionally, you can also install a number of packages to enable better user
interface toolkits. See :ref:`what-is-a-backend` for more details on the
optional Matplotlib backends and the capabilities they provide.

* :term:`tk` (>= 8.3, != 8.6.0 or 8.6.1): for the TkAgg backend;
* `PyQt4 <https://pypi.python.org/pypi/PyQt4>`_ (>= 4.4) or
`PySide <https://pypi.python.org/pypi/PySide>`_: for the Qt4Agg backend;
* `PyQt5 <https://pypi.python.org/pypi/PyQt5>`_: for the Qt5Agg backend;
* :term:`wxpython` (>= 2.9 or later): for the WX or WXAgg backend;
* `cairocffi <https://cairocffi.readthedocs.io/en/latest/>`__ (>=
v0.8): for cairo based backends;
* `pycairo <https://pypi.python.org/pypi/pycairo>`_: for GTK3Cairo;
* `Tornado <https://pypi.python.org/pypi/tornado>`_: for the WebAgg backend;
* :term:`tk` (>= 8.3, != 8.6.0 or 8.6.1): for the TkAgg backend;
* `PyQt4 <https://pypi.python.org/pypi/PyQt4>`_ (>= 4.4) or
`PySide <https://pypi.python.org/pypi/PySide>`_: for the Qt4Agg backend;
* `PyQt5 <https://pypi.python.org/pypi/PyQt5>`_: for the Qt5Agg backend;
* :term:`wxpython` (>= 4): for the WX or WXAgg backend;
* `cairocffi <https://cairocffi.readthedocs.io/en/latest/>`_ (>=0.8) or
`pycairo <https://pypi.python.org/pypi/pycairo>`_: for the cairo-based
backends (the latter is required for GTK3Cairo);
* `Tornado <https://pypi.python.org/pypi/tornado>`_: for the WebAgg backend;

For better support of animation output format and image file formats, LaTeX,
etc., you can install the following:

* `ffmpeg <https://www.ffmpeg.org/>`_/`avconv
<https://libav.org/avconv.html>`_: for saving movies;
* `ImageMagick <https://www.imagemagick.org/script/index.php>`_: for saving
animated gifs;
* `Pillow <https://pillow.readthedocs.io/en/latest/>`_ (>=3.4): for a larger selection of
image file formats: JPEG, BMP, and TIFF image files;
* `LaTeX <https://miktex.org/>`_ and `GhostScript
<https://ghostscript.com/download/>`_ (for rendering text with LaTeX).
* `ffmpeg <https://www.ffmpeg.org/>`_/`avconv
<https://libav.org/avconv.html>`_: for saving movies;
* `ImageMagick <https://www.imagemagick.org/script/index.php>`_: for saving
animated gifs;
* `Pillow <https://pillow.readthedocs.io/en/latest/>`_ (>=3.4): for a larger
selection of image file formats: JPEG, BMP, and TIFF image files;
* `LaTeX <https://miktex.org/>`_ and `GhostScript
<https://ghostscript.com/download/>`_ (for rendering text with LaTeX).

.. note::

Matplotlib depends on non-Python libraries. `pkg-config
<https://www.freedesktop.org/wiki/Software/pkg-config/>`__ can be used
<https://www.freedesktop.org/wiki/Software/pkg-config/>`_ can be used
to find required non-Python libraries and thus make the install go more
smoothly if the libraries and headers are not in the expected locations.

.. note::

The following libraries are shipped with Matplotlib:

- `Agg`: the Anti-Grain Geometry C++ rendering engine;
- `qhull`: to compute Delaunay triangulation;
- `ttconv`: a true type font utility.
- `Agg`: the Anti-Grain Geometry C++ rendering engine;
- `qhull`: to compute Delaunay triangulation;
- `ttconv`: a TrueType font utility.

.. _build_linux:

Expand Down