{% extends "layout.html" %}
{% set title = 'Matplotlib: Python plotting' %}

{% block extrahead %}
<script>
function getSnippet(id, url) {
  var req = false;
  // For Safari, Firefox, and other non-MS browsers
  if (window.XMLHttpRequest) {
    try {
      req = new XMLHttpRequest();
    } catch (e) {
      req = false;
    }
  } else if (window.ActiveXObject) {
    // For Internet Explorer on Windows
    try {
      req = new ActiveXObject("Msxml2.XMLHTTP");
    } catch (e) {
      try {
        req = new ActiveXObject("Microsoft.XMLHTTP");
      } catch (e) {
        req = false;
      }
    }
  }
  var element = document.getElementById(id);
  if (req) {
    // Synchronous request, wait till we have it all
    req.open('GET', url, false);
    req.send(null);
    if (req.status == 200) {
      element.innerHTML = req.responseText;
    } else {
      element.innerHTML = "<mark>Could not find Snippet to insert at " + url + "</mark>"
    }
  }
}
</script>

 {{ super() }}
{% endblock %}

{% block body %}

  <h1>Introduction</h1>

  <p>Matplotlib is a Python 2D plotting library which produces
  publication quality figures in a variety of hardcopy formats and
  interactive environments across platforms.  Matplotlib can be used
  in Python scripts, the Python and <a
  href="http://ipython.org">IPython</a> shell,
  the <a href="http://jupyter.org/index.html">jupyter</a> notebook,
  web application servers, and four graphical user
  interface toolkits.</p>

  <div class="responsive_screenshots">
    <a a href="{{ pathto('tutorials/introductory/sample_plots') }}">
      <div class="responsive_subfig">
        <img align="middle", src="{{ pathto('_images/sphx_glr_membrane_thumb.png', 1) }}", border="0", alt="screenshots"/>
      </div>
      <div class="responsive_subfig">
        <img align="middle", src="{{ pathto('_images/sphx_glr_histogram_thumb1.png', 1) }}", border="0", alt="screenshots"/>
      </div>
      <div class="responsive_subfig">
        <img align="middle", src="{{ pathto('_images/sphx_glr_contour_thumb.png', 1) }}", border="0", alt="screenshots"/>
      </div>
      <div class="responsive_subfig">
        <img align="middle", src="{{ pathto('_images/sphx_glr_3D_thumb.png', 1) }}", border="0", alt="screenshots"/>
      </div>
    </a>
  </div>
  <span class="clear_screenshots"></span>

  <p>Matplotlib tries to make easy things easy and hard things possible.
  You can generate plots, histograms, power spectra, bar charts,
  errorcharts, scatterplots, etc., with just a few lines of code.
  For examples, see the <a href="{{ pathto('tutorials/introductory/sample_plots')
  }}">sample plots</a> and <a href="{{ pathto('gallery/index') }}">thumbnail</a> gallery.</p>

<p>For simple plotting the <tt>pyplot</tt> module provides a
  MATLAB-like interface, particularly when combined
  with <tt>IPython</tt>.  For the power user, you have full control
  of line styles, font properties, axes properties, etc, via an object
  oriented interface or via a set of functions familiar to MATLAB
  users.</p>

  <h1>Installation</h1>

  Visit the <a href="{{ pathto('users/installing') }}">Matplotlib installation instructions</a>.

  <h1>Documentation</h1>

  This is the documentation for Matplotlib version {{ version }}.

  <p id="other_versions"></p>
  <script>
    getSnippet('other_versions', '/versions.html');
  </script>

  <p>Trying to learn how to do a particular kind of plot?  Check out
  the <a href="{{ pathto('gallery/index') }}">examples gallery</a>
  or the <a href="{{ pathto('api/pyplot_summary') }}">list of plotting
  commands</a>.</p>

  <h4>Other learning resources</h4>

  <p>There are many <a href="{{ pathto('resources/index') }}">external learning
  resources</a> available including printed material, videos and tutorials.</p>

  <h4>Need help?</h4>

<p>Matplotlib is a welcoming, inclusive project, and we try to follow
the <a href="http://www.python.org/psf/codeofconduct/">Python Software
Foundation Code of Conduct</a> in everything we do.</p>

<p>Check the <a href="{{ pathto('faq/index') }}">faq</a>,
the <a href="{{ pathto('api/index') }}">api</a> docs and
<a href="http://matplotlib.1069221.n5.nabble.com/matplotlib-users-f3.html">mailing list archives</a> for resources.
Join the <a href="https://gitter.im/matplotlib/matplotlib">gitter</a> and the mailing lists: <a href="https://mail.python.org/mailman/listinfo/matplotlib-users">Users</a>,
<a href="https://mail.python.org/mailman/listinfo/matplotlib-announce">Announce</a> and
<a href="https://mail.python.org/mailman/listinfo/matplotlib-devel">Devel</a>.
Check out the Matplotlib questions
on <a href="http://stackoverflow.com/questions/tagged/matplotlib">stackoverflow</a>.
The <a href="{{ pathto('search') }}">search</a> tool searches all of
the documentation, including full text search of over 350 complete
examples which exercise almost every corner of Matplotlib.</p>

<p>You can file bugs, patches and feature requests on the
github
<a href="https://github.com/matplotlib/matplotlib/issues?sort=created&direction=desc&state=open">tracker</a>,
but it is a good idea to ping us on the mailing list too.</p>

<p>To keep up to date with what's going on in Matplotlib, see
the <a href="{{ pathto('users/whats_new.html', 1) }}">what's new
page</a> or browse the <a href="https://github.com/matplotlib/matplotlib">source
code</a>.  Anything that could require changes to your existing code
is logged in the <a href="{{ pathto('api/api_changes.html', 1) }}">api
changes</a> file.</p>

<h1>Toolkits</h1>

<p>Matplotlib ships with several add-on <a href="{{ pathto('mpl_toolkits/index') }}">toolkits</a>,
    Including 3d plotting with <a href="{{ pathto('mpl_toolkits/mplot3d/index') }}">mplot3d</a>,
    axes helpers in <a href="{{ pathto('mpl_toolkits/axes_grid1/index') }}">axes_grid1</a> and
    axis helpers in <a href="{{ pathto('mpl_toolkits/axisartist/index') }}">axisartist</a>.
 </p>

<h1>Third party packages</h1>

<p>A large number of <a href="{{ pathto('thirdpartypackages/index') }}">third party packages</a>
    extend and build on Matplotlib functionality, including several higher-level plotting interfaces
    <a href="https://seaborn.github.io/">seaborn</a>,
    <a href="http://holoviews.org">holoviews</a>,
    <a href="http://ggplot.yhathq.com">ggplot</a>, and
    two projection and mapping toolkits
    <a href="http://matplotlib.org/basemap">basemap</a> and
    <a href="http://scitools.org.uk/cartopy/docs/latest">cartopy</a>.
</p>

<h1>Citing Matplotlib</h1>

<p>
  Matplotlib is the brainchild of John Hunter (1968-2012), who, along with its many
  contributors, have put an immeasurable amount of time and effort into producing a
  piece of software utilized by thousands of scientists worldwide.

  If Matplotlib contributes to a project that leads to a scientific publication,
  please acknowledge this work by citing the project. You can use this
  <a href="{{ pathto('citing') }}">ready-made citation entry</a>.
</p>

  <h1>Open source</h1>
  <img src="_static/numfocus_badge.png" alt="A Fiscally Sponsored Project of NUMFocus"
       style="float:right; margin-left:20px" />
<p>
Please
consider <a href="https://www.flipcause.com/widget/MjI1OA==">donating
to the Matplotlib project</a> through the Numfocus organization or to
the <a href="http://numfocus.org/johnhunter/">John Hunter Technology Fellowship</a>.
</p>

<p>
The Matplotlib <a href="{{ pathto('users/license') }}">license</a> is based on the Python Software Foundation
<a href="http://www.python.org/psf/license">(PSF)</a> license.
</p>

<p>
There is an active developer community and a long list of people
who have made significant <a href="{{ pathto('users/credits') }}">contributions</a>.
</p>

<p>
Matplotlib is hosted on <a href="https://github.com/matplotlib/matplotlib">Github</a>.
<a href="https://github.com/matplotlib/matplotlib/issues">Issues</a> and
<a href="https://github.com/matplotlib/matplotlib/pulls">Pull requests</a>
are tracked at Github too.
</p>


<div class="footnote"><p>
<sup><a name="ftn.matlab" href="#matlab">*</a></sup>
MATLAB is a registered trademark of The MathWorks, Inc.
</p>

{% endblock %}
