8000 Remove tilde in code links where not necessary by timhoffm · Pull Request #20303 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content

Remove tilde in code links where not necessary #20303

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 1 commit into from
May 26, 2021
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
6 changes: 3 additions & 3 deletions examples/axes_grid1/inset_locator_demo2.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
Inset Locator Demo2
===================

This Demo shows how to create a zoomed inset via `~.zoomed_inset_axes`.
In the first subplot an `~.AnchoredSizeBar` shows the zoom effect.
This Demo shows how to create a zoomed inset via `.zoomed_inset_axes`.
In the first subplot an `.AnchoredSizeBar` shows the zoom effect.
In the second subplot a connection to the region of interest is
created via `~.mark_inset`.
created via `.mark_inset`.
"""

from matplotlib import cbook
Expand Down
2 changes: 1 addition & 1 deletion examples/lines_bars_and_markers/stem_plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
# The parameters *linefmt*, *markerfmt*, and *basefmt* control basic format
# properties of the plot. However, in contrast to `~.pyplot.plot` not all
# properties are configurable via keyword arguments. For more advanced
# control adapt the line objects returned by `~.pyplot`.
# control adapt the line objects returned by `.pyplot`.

markerline, stemlines, baseline = plt.stem(
x, y, linefmt='grey', markerfmt='D', bottom=1.1)
Expand Down
2 changes: 1 addition & 1 deletion examples/mplot3d/stem3d_demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
# *linefmt*, *markerfmt*, and *basefmt* control basic format properties of the
# plot. However, in contrast to `~.axes3d.Axes3D.plot` not all properties are
# configurable via keyword arguments. For more advanced control adapt the line
# objects returned by `~.stem3D`.
# objects returned by `.stem3D`.

fig, ax = plt.subplots(subplot_kw=dict(projection='3d'))
markerline, stemlines, baseline = ax.stem(
Expand Down
2 changes: 1 addition & 1 deletion examples/scales/custom_scale.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Create a custom scale, by implementing the scaling use for latitude data in a
Mercator Projection.

Unless you are making special use of the `~.Transform` class, you probably
Unless you are making special use of the `.Transform` class, you probably
don't need to use this verbose method, and instead can use `~.scale.FuncScale`
and the ``'function'`` option of `~.Axes.set_xscale` and `~.Axes.set_yscale`.
See the last example in :doc:`/gallery/scales/scales`.
Expand Down
2 changes: 1 addition & 1 deletion examples/ticks_and_spines/date_concise_formatter.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
# =========================================
#
# `.ConciseDateFormatter` doesn't have rcParams entries, but localization
# can be accomplished by passing kwargs to `~.ConciseDateConverter` and
# can be accomplished by passing kwargs to `.ConciseDateConverter` and
# registering the datatypes you will use with the units registry:

import datetime
Expand Down
2 changes: 1 addition & 1 deletion examples/ticks_and_spines/date_precision_and_epochs.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def _reset_epoch_for_tutorial():

#############################################################################
# If a user wants to use modern dates at microsecond precision, they
# can change the epoch using `~.set_epoch`. However, the epoch has to be
# can change the epoch using `.set_epoch`. However, the epoch has to be
# set before any date operations to prevent confusion between different
# epochs. Trying to change the epoch later will raise a `RuntimeError`.

Expand Down
18 changes: 9 additions & 9 deletions lib/matplotlib/axes/_axes.py
Original file line number Diff line number Diff line change
Expand Up @@ -1655,7 +1655,7 @@ def plot_date(self, x, y, fmt='o', tz=None, xdate=True, ydate=False,

Returns
-------
list of `~.Line2D`
list of `.Line2D`
Objects representing the plotted data.

Other Parameters
Expand Down Expand Up @@ -1725,7 +1725,7 @@ def loglog(self, *args, **kwargs):

Returns
-------
list of `~.Line2D`
list of `.Line2D`
Objects representing the plotted data.

Other Parameters
Expand Down Expand Up @@ -1778,7 +1778,7 @@ def semilogx(self, *args, **kwargs):

Returns
-------
list of `~.Line2D`
list of `.Line2D`
Objects representing the plotted data.

Other Parameters
Expand Down Expand Up @@ -1827,7 +1827,7 @@ def semilogy(self, *args, **kwargs):

Returns
-------
list of `~.Line2D`
list of `.Line2D`
Objects representing the plotted data.

Other Parameters
Expand Down Expand Up @@ -4655,7 +4655,7 @@ def hexbin(self, x, y, C=None, gridsize=100, bins=None,

vmin, vmax : float, default: None
The colorbar range. If *None*, suitable min/max values are
automatically chosen by the `~.Normalize` instance (defaults to
automatically chosen by the `.Normalize` instance (defaults to
the respective min/max values of the bins in case of the default
linear scaling).
It is deprecated to use *vmin*/*vmax* when *norm* is given.
Expand Down Expand Up @@ -5763,7 +5763,7 @@ def pcolor(self, *args, shading=None, alpha=None, norm=None, cmap=None,

vmin, vmax : float, default: None
The colorbar range. If *None*, suitable min/max values are
automatically chosen by the `~.Normalize` instance (defaults to
automatically chosen by the `.Normalize` instance (defaults to
the respective min/max values of *C* in case of the default linear
scaling).
It is deprecated to use *vmin*/*vmax* when *norm* is given.
Expand Down Expand Up @@ -5990,7 +5990,7 @@ def pcolormesh(self, *args, alpha=None, norm=None, cmap=None, vmin=None,

vmin, vmax : float, default: None
The colorbar range. If *None*, suitable min/max values are
automatically chosen by the `~.Normalize` instance (defaults to
automatically chosen by the `.Normalize` instance (defaults to
the respective min/max values of *C* in case of the default linear
scaling).
It is deprecated to use *vmin*/*vmax* when *norm* is given.
Expand Down Expand Up @@ -6240,7 +6240,7 @@ def pcolorfast(self, *args, alpha=None, norm=None, cmap=None, vmin=None,

vmin, vmax : float, default: None
The colorbar range. If *None*, suitable min/max values are
automatically chosen by the `~.Normalize` instance (defaults to
automatically chosen by the `.Normalize` instance (defaults to
the respective min/max values of *C* in case of the default linear
scaling).
It is deprecated to use *vmin*/*vmax* when *norm* is given.
Expand Down Expand Up @@ -6381,7 +6381,7 @@ def clabel(self, CS, levels=None, **kwargs):

Parameters
----------
CS : `~.ContourSet` instance
CS : `.ContourSet` instance
Line contours to label.

levels : array-like, optional
Expand Down
18 changes: 9 additions & 9 deletions lib/matplotlib/axes/_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -2165,7 +2165,7 @@ def _deprecate_noninstance(self, _name, _types, **kwargs):

def add_artist(self, a):
"""
Add an `~.Artist` to the Axes; return the artist.
Add an `.Artist` to the Axes; return the artist.

Use `add_artist` only for artists for which there is no dedicated
"add" method; and if necessary, use a method such as `update_datalim`
Expand All @@ -2186,7 +2186,7 @@ def add_artist(self, a):

def add_child_axes(self, ax):
"""
Add an `~.AxesBase` to the axes' children; return the child axes.
Add an `.AxesBase` to the axes' children; return the child axes.

This is the lowlevel version. See `.axes.Axes.inset_axes`.
"""
Expand All @@ -2204,7 +2204,7 @@ def add_child_axes(self, ax):

def add_collection(self, collection, autolim=True):
"""
Add a `~.Collection` to the Axes; return the collection.
Add a `.Collection` to the Axes; return the collection.
"""
self._deprecate_noninstance('add_collection', mcoll.Collection,
collection=collection)
Expand Down Expand Up @@ -2238,7 +2238,7 @@ def add_collection(self, collection, autolim=True):

def add_image(self, image):
"""
Add an `~.AxesImage` to the Axes; return the image.
Add an `.AxesImage` to the Axes; return the image.
"""
self._deprecate_noninstance('add_image', mimage.AxesImage, image=image)
self._set_artist_props(image)
Expand Down Expand Up @@ -2272,7 +2272,7 @@ def add_line(self, line):

def _add_text(self, txt):
"""
Add a `~.Text` to the Axes; return the text.
Add a `.Text` to the Axes; return the text.
"""
self._deprecate_noninstance('_add_text', mtext.Text, txt=txt)
self._set_artist_props(txt)
Expand Down Expand Up @@ -2327,7 +2327,7 @@ def _update_line_limits(self, line):

def add_patch(self, p):
"""
Add a `~.Patch` to the Axes; return the patch.
Add a `.Patch` to the Axes; return the patch.
"""
self._deprecate_noninstance('add_patch', mpatches.Patch, p=p)
self._set_artist_props(p)
Expand Down Expand Up @@ -2368,7 +2368,7 @@ def _update_patch_limits(self, patch):

def add_table(self, tab):
"""
Add a `~.Table` to the Axes; return the table.
Add a `.Table` to the Axes; return the table.
"""
self._deprecate_noninstance('add_table', mtable.Table, tab=tab)
self._set_artist_props(tab)
Expand All @@ -2379,7 +2379,7 @@ def add_table(self, tab):

def add_container(self, container):
"""
Add a `~.Container` to the axes' containers; return the container.
Add a `.Container` to the axes' containers; return the container.
"""
label = container.get_label()
if not label:
Expand All @@ -2406,7 +2406,7 @@ def relim(self, visible_only=False):
"""
Recompute the data limits based on current artists.

At present, `~.Collection` instances are not supported.
At present, `.Collection` instances are not supported.

Parameters
----------
Expand Down
2 changes: 1 addition & 1 deletion lib/matplotlib/axis.py
Original file line number Diff line number Diff line change
Expand Up @@ -1797,7 +1797,7 @@ def _set_ticklabels(self, labels, fontdict=None, minor=False, **kwargs):

Returns
-------
list of `~.Text`
list of `.Text`
The labels.

Other Parameters
Expand Down
6 changes: 3 additions & 3 deletions lib/matplotlib/backend_bases.py
Original file line number Diff line number Diff line change
Expand Up @@ -1464,8 +1464,8 @@ class PickEvent(Event):
(see `.Artist.set_picker`).
other
Additional attributes may be present depending on the type of the
picked object; e.g., a `~.Line2D` pick may define different extra
attributes than a `~.PatchCollection` pick.
picked object; e.g., a `.Line2D` pick may define different extra
attributes than a `.PatchCollection` pick.

Examples
--------
Expand Down Expand Up @@ -1532,7 +1532,7 @@ def __init__(self, name, canvas, key, x=0, y=0, guiEvent=None):

def _get_renderer(figure, print_method=None):
"""
Get the renderer that would be used to save a `~.Figure`, and cache it on
Get the renderer that would be used to save a `.Figure`, and cache it on
the figure.

If you need a renderer without any active draw methods use
Expand Down
2 changes: 1 addition & 1 deletion lib/matplotlib/cbook/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1791,7 +1791,7 @@ class so far, an alias named ``get_alias`` will be defined; the same will
exception will be raised.

The alias map is stored as the ``_alias_map`` attribute on the class and
can be used by `~.normalize_kwargs` (which assumes that higher priority
can be used by `.normalize_kwargs` (which assumes that higher priority
aliases come last).
"""
if cls is None: # Return the actual class decorator.
Expand Down
10 changes: 5 additions & 5 deletions lib/matplotlib/collections.py
Original file line number Diff line number Diff line change
Expand Up @@ -1044,8 +1044,8 @@ def legend_elements(self, prop="colors", num="auto",
Finally, a `~.ticker.Locator` can be provided.
fmt : str, `~matplotlib.ticker.Formatter`, or None (default)
The format or formatter to use for the labels. If a string must be
a valid input for a `~.StrMethodFormatter`. If None (the default),
use a `~.ScalarFormatter`.
a valid input for a `.StrMethodFormatter`. If None (the default),
use a `.ScalarFormatter`.
func : function, default: ``lambda x: x``
Function to calculate the labels. Often the size (or color)
argument to `~.Axes.scatter` will have been pre-processed by the
Expand Down Expand Up @@ -1358,7 +1358,7 @@ class LineCollection(Collection):
Represents a sequence of `.Line2D`\s that should be drawn together.

This class extends `.Collection` to represent a sequence of
`~.Line2D`\s instead of just a sequence of `~.Patch`\s.
`.Line2D`\s instead of just a sequence of `.Patch`\s.
Just as in `.Collection`, each property of a *LineCollection* may be either
a single value or a list of values. This list is then used cyclically for
each element of the LineCollection, so the property of the ``i``\th element
Expand Down Expand Up @@ -1894,7 +1894,7 @@ def set_paths(self):
@staticmethod
def convert_mesh_to_paths(tri):
"""
Convert a given mesh into a sequence of `~.Path` objects.
Convert a given mesh into a sequence of `.Path` objects.

This function is primarily of use to implementers of backends that do
not directly support meshes.
Expand Down Expand Up @@ -1987,7 +1987,7 @@ def get_datalim(self, transData):
@staticmethod
def convert_mesh_to_paths(meshWidth, meshHeight, coordinates):
"""
Convert a given mesh into a sequence of `~.Path` objects.
Convert a given mesh into a sequence of `.Path` objects.

This function is primarily of use to implementers of backends that do
not directly support quadmeshes.
Expand Down
6 changes: 3 additions & 3 deletions lib/matplotlib/colorbar.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
used with figures containing a single axes or with freely placed axes.

:func:`make_axes_gridspec`
Create a `~.SubplotBase` suitable for a colorbar. This function should
Create a `.SubplotBase` suitable for a colorbar. This function should
be used for adding a colorbar to a `.GridSpec`.
"""

Expand Down Expand Up @@ -166,7 +166,7 @@
use_gridspec : bool, optional
If *cax* is ``None``, a new *cax* is created as an instance of Axes. If
*ax* is an instance of Subplot and *use_gridspec* is ``True``, *cax* is
created as an instance of Subplot using the :mod:`~.gridspec` module.
created as an instance of Subplot using the :mod:`.gridspec` module.

Returns
-------
Expand Down Expand Up @@ -1450,7 +1450,7 @@ def make_axes(parents, location=None, orientation=None, fraction=0.15,
def make_axes_gridspec(parent, *, location=None, orientation=None,
fraction=0.15, shrink=1.0, aspect=20, **kw):
"""
Create a `~.SubplotBase` suitable for a colorbar.
Create a `.SubplotBase` suitable for a colorbar.

The axes is placed in the figure of the *parent* axes, by resizing and
repositioning *parent*.
Expand Down
2 changes: 1 addition & 1 deletion lib/matplotlib/gridspec.py
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ def update(self, **kwargs):

def get_subplot_params(self, figure=None):
"""
Return the `~.SubplotParams` for the GridSpec.
Return the `.SubplotParams` for the GridSpec.

In order of precedence the values are taken from

Expand Down
2 changes: 1 addition & 1 deletion lib/matplotlib/legend.py
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ def _update_bbox_to_anchor(self, loc_in_canvas):
Whether the legend should be drawn on a patch (frame).

fancybox : bool, default: :rc:`legend.fancybox`
Whether round edges should be enabled around the `~.FancyBboxPatch` which
Whether round edges should be enabled around the `.FancyBboxPatch` which
makes up the legend's background.

shadow : bool, default: :rc:`legend.shadow`
Expand Down
10 changes: 5 additions & 5 deletions lib/matplotlib/path.py
Original file line number Diff line number Diff line change
Expand Up @@ -1045,18 +1045,18 @@ def clip_to_bbox(self, bbox, inside=True):
def get_path_collection_extents(
master_transform, paths, transforms, offsets, offset_transform):
r"""
Given a sequence of `Path`\s, `~.Transform`\s objects, and offsets, as
found in a `~.PathCollection`, returns the bounding box that encapsulates
Given a sequence of `Path`\s, `.Transform`\s objects, and offsets, as
found in a `.PathCollection`, returns the bounding box that encapsulates
all of them.

Parameters
----------
master_transform : `~.Transform`
master_transform : `.Transform`
Global transformation applied to all paths.
paths : list of `Path`
transforms : list of `~.Affine2D`
transforms : list of `.Affine2D`
offsets : (N, 2) array-like
offset_transform : `~.Affine2D`
offset_transform : `.Affine2D`
Transform applied to the offsets before offsetting the path.

Notes
Expand Down
4 changes: 2 additions & 2 deletions lib/matplotlib/patheffects.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"""
Defines classes for path effects. The path effects are supported in `~.Text`,
`~.Line2D` and `~.Patch`.
Defines classes for path effects. The path effects are supported in `.Text`,
`.Line2D` and `.Patch`.

.. seealso::
:doc:`/tutorials/advanced/patheffects_guide`
Expand Down
4 changes: 2 additions & 2 deletions lib/matplotlib/projections/polar.py
Original file line number Diff line number Diff line change
Expand Up @@ -1325,7 +1325,7 @@ def set_thetagrids(self, angles, labels=None, fmt=None, **kwargs):
Other Parameters
----------------
**kwargs
*kwargs* are optional `~.Text` properties for the labels.
*kwargs* are optional `.Text` properties for the labels.

See Also
--------
Expand Down Expand Up @@ -1377,7 +1377,7 @@ def set_rgrids(self, radii, labels=None, angle=None, fmt=None, **kwargs):
Other Parameters
----------------
**kwargs
*kwargs* are optional `~.Text` properties for the labels.
*kwargs* are optional `.Text` properties for the labels.

See Also
--------
Expand Down
Loading
0