Skip to content

Commit

Permalink
Document plot directive usage
Browse files Browse the repository at this point in the history
  • Loading branch information
jnothman committed Nov 1, 2017
1 parent 04c9d99 commit 5b1169f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions doc/format.rst
Original file line number Diff line number Diff line change
Expand Up @@ -443,6 +443,13 @@ The sections of a function's docstring are:
``import matplotlib.pyplot as plt``. All other imports, including the
demonstrated function, must be explicit.

When matplotlib is imported in the example, the Example code will be
wrapped in `matplotlib's Sphinx `plot` directive
<http://matplotlib.org/sampledoc/extensions.html>`_. When matplotlib is
not explicitly imported, `.. plot::` can be used directly if
`matplotlib.sphinxext.plot_directive` is loaded as a Sphinx extension in
``conf.py``.


Documenting classes
-------------------
Expand Down

0 comments on commit 5b1169f

Please sign in to comment.