Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Replace :ref:sphx_glr_... by :doc:/.... #11312

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 29, 2018
Merged
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions doc/api/api_changes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ New dependency

`kiwisolver <https://github.com/nucleic/kiwi>`__ is now a required
dependency to support the new constrained_layout, see
:ref:`sphx_glr_tutorials_intermediate_constrainedlayout_guide.py` for
:doc:`/tutorials/intermediate/constrainedlayout_guide` for
more details.


Expand Down Expand Up @@ -1603,7 +1603,7 @@ original location:
* The legend handler interface has changed from a callable, to any object
which implements the ``legend_artists`` method (a deprecation phase will
see this interface be maintained for v1.4). See
:ref:`sphx_glr_tutorials_intermediate_legend_guide.py` for further details. Further legend changes
:doc:`/tutorials/intermediate/legend_guide` for further details. Further legend changes
include:

* :func:`matplotlib.axes.Axes._get_legend_handles` now returns a generator
Expand Down
4 changes: 2 additions & 2 deletions doc/api/pyplot_summary.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ The Pyplot API
The :mod:`matplotlib.pyplot` module contains functions that allow you to generate
many kinds of plots quickly. For examples that showcase the use
of the :mod:`matplotlib.pyplot` module, see the
:ref:`sphx_glr_tutorials_introductory_pyplot.py`
:doc:`/tutorials/introductory/pyplot`
or the :ref:`pyplots_examples`. We also recommend that you look into
the object-oriented approach to plotting, described below.

Expand Down Expand Up @@ -38,6 +38,6 @@ There are many colormaps you can use to map data onto color values.
Below we list several ways in which color can be utilized in Matplotlib.

For a more in-depth look at colormaps, see the
:ref:`sphx_glr_tutorials_colors_colormaps.py` tutorial.
:doc:`/tutorials/colors/colormaps` tutorial.

.. autofunction:: colormaps
2 changes: 1 addition & 1 deletion doc/api/toolkits/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ mplot3d
plotting (scatter, surf, line, mesh) tools. Not the fastest or most feature
complete 3D library out there, but it ships with Matplotlib and thus may be a
lighter weight solution for some use cases. Check out the
:ref:`mplot3d tutorial <sphx_glr_tutorials_toolkits_mplot3d.py>` for more
:doc:`mplot3d tutorial </tutorials/toolkits/mplot3d>` for more
information.

.. figure:: ../../gallery/mplot3d/images/sphx_glr_contourf3d_2_001.png
Expand Down
2 changes: 1 addition & 1 deletion doc/api/toolkits/mplot3d/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ The mplot3d toolkit adds simple 3D plotting capabilities to matplotlib by
supplying an axes object that can create a 2D projection of a 3D scene.
The resulting graph will have the same look and feel as regular 2D plots.

See the :ref:`mplot3d tutorial <sphx_glr_tutorials_toolkits_mplot3d.py>` for
See the :doc:`mplot3d tutorial </tutorials/toolkits/mplot3d>` for
more information on how to use this toolkit.

.. image:: /_static/demo_mplot3d.png
Expand Down
2 changes: 1 addition & 1 deletion doc/devel/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ Developing a new backend
------------------------

If you are working on a custom backend, the *backend* setting in
:file:`matplotlibrc` (:ref:`sphx_glr_tutorials_introductory_customizing.py`) supports an
:file:`matplotlibrc` (:doc:`/tutorials/introductory/customizing`) supports an
external backend via the ``module`` directive. If
:file:`my_backend.py` is a Matplotlib backend in your
:envvar:`PYTHONPATH`, you can set it on one of several ways
Expand Down
16 changes: 8 additions & 8 deletions doc/faq/howto_faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ If you only want to use the `pandas` converter for `datetime64` values ::
Find all objects in a figure of a certain type
----------------------------------------------

Every Matplotlib artist (see :ref:`sphx_glr_tutorials_intermediate_artists.py`) has a method
Every Matplotlib artist (see :doc:`/tutorials/intermediate/artists`) has a method
called :meth:`~matplotlib.artist.Artist.findobj` that can be used to
recursively search the artist for any artists it may contain that meet
some criteria (e.g., match all :class:`~matplotlib.lines.Line2D`
Expand Down Expand Up @@ -159,7 +159,7 @@ labels::
ax = fig.add_subplot(111)

You can control the defaults for these parameters in your
:file:`matplotlibrc` file; see :ref:`sphx_glr_tutorials_introductory_customizing.py`. For
:file:`matplotlibrc` file; see :doc:`/tutorials/introductory/customizing`. For
example, to make the above setting permanent, you would set::

figure.subplot.bottom : 0.2 # the bottom of the subplots of the figure
Expand Down Expand Up @@ -190,7 +190,7 @@ specify the location explicitly::
ax = fig.add_axes([left, bottom, width, height])

where all values are in fractional (0 to 1) coordinates. See
:ref:`sphx_glr_gallery_subplots_axes_and_figures_axes_demo.py` for an example of placing axes manually.
:doc:`/gallery/subplots_axes_and_figures/axes_demo` for an example of placing axes manually.

.. _howto-auto-adjust:

Expand All @@ -200,7 +200,7 @@ Automatically make room for tick labels
.. note::
This is now easier to handle than ever before.
Calling :func:`~matplotlib.pyplot.tight_layout` can fix many common
layout issues. See the :ref:`sphx_glr_tutorials_intermediate_tight_layout_guide.py`.
layout issues. See the :doc:`/tutorials/intermediate/tight_layout_guide`.

The information below is kept here in case it is useful for other
purposes.
Expand Down Expand Up @@ -352,7 +352,7 @@ and patches, respectively::

.. only:: html

See :ref:`sphx_glr_gallery_misc_zorder_demo.py` for a complete example.
See :doc:`/gallery/misc/zorder_demo` for a complete example.

You can also use the Axes property
:meth:`~matplotlib.axes.Axes.set_axisbelow` to control whether the grid
Expand All @@ -371,7 +371,7 @@ some ratio which controls the ratio::

.. only:: html

See :ref:`sphx_glr_gallery_subplots_axes_and_figures_axis_equal_demo.py` for a
See :doc:`/gallery/subplots_axes_and_figures/axis_equal_demo` for a
complete example.

.. _howto-twoscale:
Expand Down Expand Up @@ -415,7 +415,7 @@ locators as desired because the two axes are independent.

.. only:: html

See :ref:`sphx_glr_gallery_api_two_scales.py` for a complete example
See :doc:`/gallery/api/two_scales` for a complete example

.. _howto-batch:

Expand Down Expand Up @@ -661,7 +661,7 @@ For more on configuring your backend, see

Alternatively, you can avoid pylab/pyplot altogether, which will give
you a little more control, by calling the API directly as shown in
:ref:`sphx_glr_gallery_api_agg_oo_sgskip.py`.
:doc:`/gallery/api/agg_oo_sgskip`.

You can either generate hardcopy on the filesystem by calling savefig::

Expand Down
2 changes: 1 addition & 1 deletion doc/faq/installing_faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ example::

This will give you additional information about which backends matplotlib is
loading, version information, and more. At this point you might want to make
sure you understand matplotlib's :ref:`configuration <sphx_glr_tutorials_introductory_customizing.py>`
sure you understand matplotlib's :doc:`configuration </tutorials/introductory/customizing>`
process, governed by the :file:`matplotlibrc` configuration file which contains
instructions within and the concept of the matplotlib backend.

Expand Down
2 changes: 1 addition & 1 deletion doc/faq/troubleshooting_faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ provide the following information in your e-mail to the `mailing list
`Enthought Canopy <https://www.enthought.com/products/canopy/>`_).

* Any customizations to your ``matplotlibrc`` file (see
:ref:`sphx_glr_tutorials_introductory_customizing.py`).
:doc:`/tutorials/introductory/customizing`).

* If the problem is reproducible, please try to provide a *minimal*, standalone
Python script that demonstrates the problem. This is *the* critical step.
Expand Down
4 changes: 2 additions & 2 deletions doc/users/dflt_style_changes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ are only specified via hex values. To access these colors outside of
the property cycling the notation for colors ``'CN'``, where ``N``
takes values 0-9, was added to
denote the first 10 colors in ``mpl.rcParams['axes.prop_cycle']`` See
:ref:`sphx_glr_tutorials_colors_colors.py` for more details.
:doc:`/tutorials/colors/colors` for more details.

To restore the old color cycle use

Expand Down Expand Up @@ -145,7 +145,7 @@ watch Nathaniel Smith and Stéfan van der Walt's talk from SciPy2015.
See `here for many more details <https://bids.github.io/colormap/>`__
about the other alternatives and the tools used to create the color
map. For details on all of the color maps available in matplotlib see
:ref:`sphx_glr_tutorials_colors_colormaps.py`.
:doc:`/tutorials/colors/colormaps`.

.. raw:: html

Expand Down
2 changes: 1 addition & 1 deletion doc/users/prev_whats_new/whats_new_0.98.4.rst
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ psd amplitude scaling

Ryan May did a lot of work to rationalize the amplitude scaling of
:func:`~matplotlib.pyplot.psd` and friends. See
:ref:`sphx_glr_gallery_lines_bars_and_markers_psd_demo.py`.
:doc:`/gallery/lines_bars_and_markers/psd_demo`.
The changes should increase MATLAB
compatibility and increase scaling options.

Expand Down
10 changes: 5 additions & 5 deletions doc/users/prev_whats_new/whats_new_0.99.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ New in matplotlib 0.99
New documentation
-----------------

Jae-Joon Lee has written two new guides :ref:`sphx_glr_tutorials_intermediate_legend_guide.py`
Jae-Joon Lee has written two new guides :doc:`/tutorials/intermediate/legend_guide`
and :ref:`plotting-guide-annotation`. Michael Sarahan has written
:ref:`sphx_glr_tutorials_introductory_images.py`. John Hunter has written two new tutorials on
working with paths and transformations: :ref:`sphx_glr_tutorials_advanced_path_tutorial.py` and
:ref:`sphx_glr_tutorials_advanced_transforms_tutorial.py`.
:doc:`/tutorials/introductory/images`. John Hunter has written two new tutorials on
working with paths and transformations: :doc:`/tutorials/advanced/path_tutorial` and
:doc:`/tutorials/advanced/transforms_tutorial`.

.. _whats-new-mplot3d:

Expand Down Expand Up @@ -65,7 +65,7 @@ that denote the data limits -- in various arbitrary locations. No
longer are your axis lines constrained to be a simple rectangle around
the figure -- you can turn on or off left, bottom, right and top, as
well as "detach" the spine to offset it away from the data. See
:ref:`sphx_glr_gallery_ticks_and_spines_spine_placement_demo.py` and
:doc:`/gallery/ticks_and_spines/spine_placement_demo` and
:class:`matplotlib.spines.Spine`.

.. figure:: ../../gallery/pyplots/images/sphx_glr_whats_new_99_spines_001.png
Expand Down
4 changes: 2 additions & 2 deletions doc/users/prev_whats_new/whats_new_1.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Sophisticated subplot grid layout

Jae-Joon Lee has written :mod:`~matplotlib.gridspec`, a new module for
doing complex subplot layouts, featuring row and column spans and
more. See :ref:`sphx_glr_tutorials_intermediate_gridspec.py` for a tutorial overview.
more. See :doc:`/tutorials/intermediate/gridspec` for a tutorial overview.

.. figure:: ../../gallery/userdemo/images/sphx_glr_demo_gridspec01_000.png
:target: ../../gallery/userdemo/demo_gridspec01.html
Expand All @@ -44,7 +44,7 @@ indexing (starts with 0). e.g.::
fig, axarr = plt.subplots(2, 2)
axarr[0,0].plot([1,2,3]) # upper, left

See :ref:`sphx_glr_gallery_subplots_axes_and_figures_subplot_demo.py` for several code examples.
See :doc:`/gallery/subplots_axes_and_figures/subplot_demo` for several code examples.

Contour fixes and and triplot
---------------------------------
Expand Down
8 changes: 4 additions & 4 deletions doc/users/prev_whats_new/whats_new_1.1.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ Sankey Diagrams

Kevin Davies has extended Yannick Copin's original Sankey example into a module
(:mod:`~matplotlib.sankey`) and provided new examples
(:ref:`sphx_glr_gallery_api_sankey_basics.py`, :ref:`sphx_glr_gallery_api_sankey_links.py`,
:ref:`sphx_glr_gallery_api_sankey_rankine.py`).
(:doc:`/gallery/api/sankey_basics`, :doc:`/gallery/api/sankey_links`,
:doc:`/gallery/api/sankey_rankine`).

.. figure:: ../../gallery/api/images/sphx_glr_sankey_rankine_001.png
:target: ../../gallery/api/sankey_rankine.html
Expand Down Expand Up @@ -87,7 +87,7 @@ The usage of this functionality can be as simple as ::

and it will adjust the spacing between subplots
so that the axis labels do not overlap with neighboring subplots. A
:ref:`sphx_glr_tutorials_intermediate_tight_layout_guide.py` has been created to show how to use
:doc:`/tutorials/intermediate/tight_layout_guide` has been created to show how to use
this new tool.

PyQT4, PySide, and IPython
Expand Down Expand Up @@ -116,7 +116,7 @@ legends for complex plots such as :meth:`~matplotlib.pyplot.stem` plots
will now display correctly. Second, the 'best' placement of a legend has
been improved in the presence of NANs.

See the :ref:`sphx_glr_tutorials_intermediate_legend_guide.py` for more detailed explanation and
See the :doc:`/tutorials/intermediate/legend_guide` for more detailed explanation and
examples.

.. figure:: ../../gallery/text_labels_and_annotations/images/sphx_glr_legend_demo_004.png
Expand Down
2 changes: 1 addition & 1 deletion doc/users/prev_whats_new/whats_new_1.2.rst
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ PGF/TikZ backend
Peter Würtz wrote a backend that allows matplotlib to export figures as
drawing commands for LaTeX. These can be processed by PdfLaTeX, XeLaTeX or
LuaLaTeX using the PGF/TikZ package. Usage examples and documentation are
found in :ref:`sphx_glr_tutorials_text_pgf.py`.
found in :doc:`/tutorials/text/pgf`.

.. image:: /_static/pgf_preamble.*

Expand Down
6 changes: 3 additions & 3 deletions doc/users/prev_whats_new/whats_new_1.4.rst
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ with :func:`~matplotlib.Axes.bxp`.
Lastly, each artist (e.g., the box, outliers, cap, notches) can now be
toggled on or off and their styles can be passed in through individual
kwargs. See the examples:
:ref:`sphx_glr_gallery_statistics_boxplot.py` and
:ref:`sphx_glr_gallery_statistics_bxp.py`
:doc:`/gallery/statistics/boxplot` and
:doc:`/gallery/statistics/bxp`

Added a bool kwarg, :code:`manage_xticks`, which if False disables the management
of the ticks and limits on the x-axis by :func:`~matplotlib.axes.Axes.bxp`.
Expand Down Expand Up @@ -410,7 +410,7 @@ instead of ``:context:`` any time you want to reset the context.

Legend and PathEffects documentation
------------------------------------
The :ref:`sphx_glr_tutorials_intermediate_legend_guide.py` and :ref:`sphx_glr_tutorials_advanced_patheffects_guide.py` have both been
The :doc:`/tutorials/intermediate/legend_guide` and :doc:`/tutorials/advanced/patheffects_guide` have both been
updated to better reflect the full potential of each of these powerful
features.

Expand Down
2 changes: 1 addition & 1 deletion doc/users/prev_whats_new/whats_new_1.5.rst
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@ mutually exclusive inside that group. For tools derived from
that are called automatically whenever it is toggled.


A full example is located in :ref:`sphx_glr_gallery_user_interfaces_toolmanager_sgskip.py`
A full example is located in :doc:`/gallery/user_interfaces/toolmanager_sgskip`


cbook.is_sequence_of_strings recognizes string objects
Expand Down
2 changes: 1 addition & 1 deletion doc/users/prev_whats_new/whats_new_2.0.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ Filled ``+`` and ``x`` markers

New fillable *plus* and *x* markers have been added. See
the :mod:`~matplotlib.markers` module and
:ref:`marker reference <sphx_glr_gallery_lines_bars_and_markers_marker_reference.py>`
:doc:`marker reference </gallery/lines_bars_and_markers/marker_reference>`
examples.

`rcount` and `ccount` for `plot_surface()`
Expand Down
2 changes: 1 addition & 1 deletion doc/users/prev_whats_new/whats_new_2.1.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ PolygonSelector

A :class:`~matplotlib.widgets.PolygonSelector` class has been added to
:mod:`matplotlib.widgets`. See
:ref:`sphx_glr_gallery_widgets_polygon_selector_demo.py` for details.
:doc:`/gallery/widgets/polygon_selector_demo` for details.


Added `matplotlib.ticker.PercentFormatter`
Expand Down
2 changes: 1 addition & 1 deletion doc/users/shell.rst
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ are going to need to understand what a matplotlib backend is
With the TkAgg backend, which uses the Tkinter user interface toolkit,
you can use matplotlib from an arbitrary non-gui python shell. Just set your
``backend : TkAgg`` and ``interactive : True`` in your
:file:`matplotlibrc` file (see :ref:`sphx_glr_tutorials_introductory_customizing.py`) and fire
:file:`matplotlibrc` file (see :doc:`/tutorials/introductory/customizing`) and fire
up python. Then::

>>> from pylab import *
Expand Down
2 changes: 1 addition & 1 deletion examples/axes_grid1/simple_anchored_artists.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
This example illustrates the use of the anchored helper classes found in
:py:mod:`~matplotlib.offsetbox` and in the :ref:`toolkit_axesgrid1-index`.
An implementation of a similar figure, but without use of the toolkit,
can be found in :ref:`sphx_glr_gallery_misc_anchored_artists.py`.
can be found in :doc:`/gallery/misc/anchored_artists`.
"""

import matplotlib.pyplot as plt
Expand Down
2 changes: 1 addition & 1 deletion examples/color/color_cycle_default.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
====================================

Display the colors from the default prop_cycle, which is obtained from the
:ref:`rc parameters<sphx_glr_tutorials_introductory_customizing.py>`.
:doc:`rc parameters</tutorials/introductory/customizing>`.
"""
import numpy as np
import matplotlib.pyplot as plt
Expand Down
9 changes: 4 additions & 5 deletions examples/color/color_cycler.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,10 @@

This example demonstrates two different APIs:

1. Setting the default
:ref:`rc parameter<sphx_glr_tutorials_introductory_customizing.py>`
specifying the property cycle. This affects all subsequent axes
(but not axes already created).
2. Setting the property cycle for a single pair of axes.
1. Setting the default :doc:`rc parameter</tutorials/introductory/customizing>`
specifying the property cycle. This affects all subsequent axes (but not
axes already created).
2. Setting the property cycle for a single pair of axes.
"""
from cycler import cycler
import numpy as np
Expand Down
4 changes: 2 additions & 2 deletions examples/color/color_demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@

For more information on colors in matplotlib see

* the :ref:`sphx_glr_tutorials_colors_colors.py` tutorial;
* the :doc:`/tutorials/colors/colors` tutorial;
* the `matplotlib.colors` API;
* the :ref:`sphx_glr_gallery_color_named_colors.py` example.
* the :doc:`/gallery/color/named_colors` example.
"""

import matplotlib.pyplot as plt
Expand Down
4 changes: 2 additions & 2 deletions examples/color/named_colors.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@

For more information on colors in matplotlib see

* the :ref:`sphx_glr_tutorials_colors_colors.py` tutorial;
* the :doc:`/tutorials/colors/colors` tutorial;
* the `matplotlib.colors` API;
* the :ref:`sphx_glr_gallery_color_color_demo.py`.
* the :doc:`/gallery/color/color_demo`.
"""

import matplotlib.pyplot as plt
Expand Down
5 changes: 2 additions & 3 deletions examples/images_contours_and_fields/contour_demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,8 @@
Illustrate simple contour plotting, contours on an image with
a colorbar for the contours, and labelled contours.

See also the
:ref:`contour image example
<sphx_glr_gallery_images_contours_and_fields_contour_image.py>`.
See also the :doc:`contour image example
</gallery/images_contours_and_fields/contour_image>`.
"""
import matplotlib
import numpy as np
Expand Down
Loading