@@ -12,8 +12,11 @@ installed, and how you want to use it. To avoid wading through all
12
12
the details (and potential complications) on this page, there are several
13
13
convenient options.
14
14
15
+ Installing pre-built packages
16
+ =============================
17
+
15
18
Most platforms : scientific Python distributions
16
- ================================================
19
+ ------------------------------------------------
17
20
18
21
The first option is to use one of the pre-packaged python distributions that
19
22
already provide matplotlib built-in. The Continuum.io Python distribution
@@ -24,88 +27,26 @@ Linux platforms. Both of these distributions include matplotlib and *lots* of
24
27
other useful tools. Another excellent alternative for Windows users is
25
28
`Python (x, y) <https://code.google.com/p/pythonxy>`_ .
26
29
30
+
27
31
Linux : using your package manager
28
- ==================================
32
+ ----------------------------------
29
33
30
34
If you are on Linux, you might prefer to use your package manager. matplotlib
31
35
is packaged for almost every major Linux distribution.
32
36
33
37
* Debian / Ubuntu : ``sudo apt-get install python-matplotlib``
34
38
* Fedora / Redhat : ``sudo yum install python-matplotlib``
35
39
36
- Mac OSX - using pip
37
- ===================
40
+ Mac OSX : using pip
41
+ -------------------
38
42
39
43
If you are on Mac OSX you can probably install matplotlib binaries using the
40
44
standard Python installation program `pip <https://pypi.python.org/pip>`_.
41
- See :ref:`installing-osx-binaries`.
42
-
43
- Manually installing pre-built packages
44
- ======================================
45
-
46
- General instructions
47
- --------------------
48
-
49
- For some people, the prepackaged pythons discussed above are not an
50
- option. That's OK, it's usually pretty easy to get a custom install
51
- working. You will first need to find out if you have python installed
52
- on your machine, and if not, install it. The official python builds
53
- are available for download `here <http://www.python.org/download>`_,
54
- but OS X users please read :ref:`which-python-for-osx`.
55
-
56
- Once you have Python up and running, you will need to install `numpy
57
- <http://www.numpy.org/>`_. numpy provides high-performance array data
58
- structures and mathematical functions, and is a requirement for
59
- matplotlib. You can test your progress::
60
-
61
- >>> import numpy
62
- >>> print numpy.__version__
63
-
64
- matplotlib requires numpy version |minimum_numpy_version| or later.
65
- Although it is not a requirement to use matplotlib, we strongly
66
- encourage you to install `ipython <http://ipython.org>`_, which is an
67
- interactive shell for python that is matplotlib-aware.
68
-
69
- Next, we need to get matplotlib installed. We provide prebuilt
70
- binaries for OS X and Windows on the matplotlib `download
71
- <http://matplotlib.org/downloads.html>`_. Click on
72
- the latest release of the "matplotlib" package, choose your python
73
- version (2.6, 2.7, 3.3, or 3.4) and your platform (macosx or win32). If you
74
- have any problems, please check the :ref:`installing-faq`, search
75
- using Google, and/or post a question the `mailing list
76
- <http://sourceforge.net/project/showfiles.php?group_id=80706>`_.
77
-
78
- If you are on Debian/Ubuntu linux, it suffices to do::
45
+ See :ref:`install_osx_binaries`.
79
46
80
- > sudo apt-get install python-matplotlib
81
47
82
- Instructions for installing our OSX binaries are found in the FAQ
83
- :ref:`install_osx_binaries`.
84
-
85
-
86
- Once you have ipython, numpy and matplotlib installed, you can use
87
- ipython's "pylab" mode to have a MATLAB-like environment that automatically
88
- handles most of the configuration details for you, so you can get up
89
- and running quickly::
90
-
91
- johnh@flag:~> ipython -pylab
92
- Python 2.4.5 (#4, Apr 12 2008, 09:09:16)
93
- IPython 0.9.0 -- An enhanced Interactive Python.
94
-
95
- Welcome to pylab, a matplotlib-based Python environment.
96
- For more information, type 'help(pylab)'.
97
-
98
- In [1]: x = randn(10000)
99
-
100
- In [2]: hist(x, 100)
101
-
102
- Note that when testing matplotlib installations from the interactive
103
- python console, there are some issues relating to user interface
104
- toolkits and interactive settings that are discussed in
105
- :ref:`mpl-shell`.
106
-
107
- Installing on Windows
108
- ---------------------
48
+ Windows
49
+ -------
109
50
110
51
If you don't already have Python installed, we recommend using
111
52
one of the `scipy-stack compatible Python distributions
@@ -175,6 +116,8 @@ sys.prefix\Lib\site-packages\mpl_toolkits respectively, and install
175
116
Pillow, MiKTeX, GhostScript, ffmpeg, avconv, mencoder, ImageMagick, and
176
117
`Inkscape <http://inkscape.org/>`_.
177
118
119
+
120
+
178
121
.. _install_from_source:
179
122
180
123
Installing from source
0 commit comments