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

Skip to content

Commit 2b00840

Browse files
committed
addressing comments
1 parent b7d733e commit 2b00840

File tree

7 files changed

+71
-70
lines changed

7 files changed

+71
-70
lines changed

doc/api/toolkits/axes_grid.rst

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,11 @@ Axes Grid
1313
---------
1414
.. note::
1515

16-
There is an older version of the AxesGrid toolkit, simply called ``axes_grid`` instead of
17-
``axes_grid1``. the toolkit had a single namespace of axes_grid. This toolkit was broken
18-
into the two modules below. For the documentation on the original ``axes_grid``
19-
module, see the `previous version of the docs
16+
There is an older version of the AxesGrid toolkit, ``axes_grid`` (instead of
17+
``axes_grid1``). The old version had a single namespace for all axes_grid
18+
objects, and in the new version this toolkit was broken
19+
into the two modules below. For the documentation on ``axes_grid``,
20+
see the `previous version of the docs
2021
<http://matplotlib.org/2.0.1/mpl_toolkits/axes_grid/index.html#toolkit-axesgrid-index>`_.
2122

2223
.. autosummary::

doc/api/toolkits/mplot3d.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,13 @@ mplot3d API
3333
===================================
3434

3535
.. note::
36-
Historically, axis3d has suffered from having hard-coded constants
37-
controlling the look and feel of the 3D plot. This precluded user
38-
level adjustments such as label spacing, font colors and panel colors.
39-
For version 1.1.0, these constants have been consolidated into a single
40-
private member dictionary, `self._axinfo`, for the axis object. This is
41-
intended only as a stop-gap measure to allow user-level customization,
42-
but it is not intended to be permanent.
36+
See :attr:`mpl_toolkits.mplot3d.axis3d._axinfo` for a dictionary containing
37+
constants that may be modified for controlling the look and feel
38+
of mplot3d axes (e.g., label spacing, font colors and panel colors).
39+
Historically, axis3d has suffered from having hard-coded constants
40+
that precluded user adjustments, and this dictionary was implemented
41+
in version 1.1 as a stop-gap measure.
42+
4343

4444
.. autosummary::
4545
:toctree: ../_as_gen

doc/mpl_toolkits/axisartist/index.rst

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
Matplotlib axisartist Toolkit
44
=============================
55

6-
The *axisartist* namespace includes a derived Axes implementation. The
7-
biggest difference is that the artists responsible to draw axis line,
8-
ticks, ticklabel and axis labels are separated out from the mpl's Axis
9-
class, which are much more than artists in the original mpl. This
10-
change was strongly motivated to support curvilinear grid.
6+
The *axisartist* namespace includes a derived Axes implementation (
7+
:class:`mpl_toolkits.axisartist.Axes`). The
8+
biggest difference is that the artists that are responsible for drawing
9+
axis lines, ticks, ticklabels, and axis labels are separated out from the
10+
mpl's Axis class. This change was strongly motivated to support curvilinear grid.
1111

1212
You can find a tutorial describing usage of axisartist at
1313
:ref:`axisartist_users-guide-index`.

doc/mpl_toolkits/index.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ mplot3d
1818
=======
1919

2020
:mod:`mpl_toolkits.mplot3d` provides some basic 3D
21-
plotting (scatter, surf, line, mesh) tools. Not the fastest or feature
22-
complete 3D library out there, but ships with Matplotlib and thus may be a
21+
plotting (scatter, surf, line, mesh) tools. Not the fastest or most feature
22+
complete 3D library out there, but it ships with Matplotlib and thus may be a
2323
lighter weight solution for some use cases. Check out the
2424
:ref:`mplot3d tutorial <sphx_glr_tutorials_toolkits_mplot3d.py>` for more
2525
information.
@@ -47,7 +47,7 @@ axes_grid1
4747
==========
4848

4949
The :mod:`mpl_toolkits.axes_grid1` toolkit is a
50-
collection of helper classes to ease displaying multiple axes in Matplotlib.
50+
collection of helper classes for displaying multiple axes in Matplotlib.
5151

5252
.. image:: /_static/demo_axes_grid.png
5353

@@ -63,7 +63,7 @@ axisartist
6363
==========
6464

6565
The :mod:`mpl_toolkits.axisartist` toolkit contains
66-
a custom Axes class that is meant to support for curvilinear grids.
66+
a custom Axes class that is meant to support curvilinear grids.
6767

6868
.. toctree::
6969
:maxdepth: 2

lib/mpl_toolkits/axisartist/axislines.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
"""
22
Axislines includes modified implementation of the Axes class. The
3-
biggest difference is that the artists responsible to draw axis line,
4-
ticks, ticklabel and axis labels are separated out from the mpl's Axis
5-
class, which are much more than artists in the original
6-
mpl. Originally, this change was motivated to support curvilinear
7-
grid. Here are a few reasons that I came up with new axes class.
3+
biggest difference is that the artists responsible for drawing the axis spine,
4+
ticks, ticklabels and axis labels are separated out from mpl's Axis
5+
class. Originally, this change was motivated to support curvilinear
6+
grid. Here are a few reasons that I came up with a new axes class:
87
98
109
* "top" and "bottom" x-axis (or "left" and "right" y-axis) can have

tutorials/toolkits/axes_grid.py

Lines changed: 27 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
(multiple) images with matplotlib. In matplotlib, the axes location
1515
(and size) is specified in the normalized figure coordinates, which
1616
may not be ideal for displaying images that needs to have a given
17-
aspect ratio. For example, it helps you to have a colorbar whose
17+
aspect ratio. For example, it helps if you have a colorbar whose
1818
height always matches that of the image. `ImageGrid`_, `RGB Axes`_ and
1919
`AxesDivider`_ are helper classes that deals with adjusting the
2020
location of (multiple) Axes. They provides a framework to adjust the
@@ -276,7 +276,7 @@
276276
Example 2. twin
277277
~~~~~~~~~~~~~~~
278278
279-
*twin* without a transform argument treat the parasite axes to have a
279+
*twin* without a transform argument assumes that the parasite axes has the
280280
same data transform as the host. This can be useful when you want the
281281
top(or right)-axis to have different tick-locations, tick-labels, or
282282
tick-formatter for bottom(or left)-axis. ::
@@ -407,23 +407,24 @@
407407
AxesDivider
408408
===========
409409
410-
The axes_divider module provide helper classes to adjust the axes
411-
positions of set of images in the drawing time.
410+
The axes_divider module provides helper classes to adjust the axes
411+
positions of a set of images at drawing time.
412412
413-
* :mod:`~mpl_toolkits.axes_grid1.axes_size` provides a classes of
414-
units that the size of each axes will be determined. For example,
415-
you can specify a fixed size
413+
* :mod:`~mpl_toolkits.axes_grid1.axes_size` provides a class of
414+
units that are used to determine the size of each axes. For example,
415+
you can specify a fixed size.
416416
417-
* :class:`~mpl_toolkits.axes_grid1.axes_size.Divider` this is the class
418-
that is used calculates the axes position. It divides the given
419-
rectangular area into several areas. You initialize the divider by
420-
setting the horizontal and vertical list of sizes that the division
421-
will be based on. You then use the new_locator method, whose return
422-
value is a callable object that can be used to set the axes_locator
423-
of the axes.
417+
* :class:`~mpl_toolkits.axes_grid1.axes_size.Divider` is the class
418+
that calculates the axes position. It divides the given
419+
rectangular area into several areas. The divider is initialized by
420+
setting the lists of horizontal and vertical sizes on which the division
421+
will be based. Then use
422+
:meth:`~mpl_toolkits.axes_grid1.axes_size.Divider.new_locator`,
423+
which returns a callable object that can be used to set the
424+
axes_locator of the axes.
424425
425426
426-
You first initialize the divider by specifying its grids, i.e.,
427+
First, initialize the divider by specifying its grids, i.e.,
427428
horizontal and vertical.
428429
429430
for example,::
@@ -454,37 +455,37 @@
454455
* v2 => 3, 0
455456
456457
The height of the bottom row is always 2 (axes_divider internally
457-
assumes that the unit is inch). The first and the second rows with
458-
height ratio of 2:3. For example, if the total height of the grid 6,
458+
assumes that the unit is inches). The first and the second rows have a
459+
height ratio of 2:3. For example, if the total height of the grid is 6,
459460
then the first and second row will each occupy 2/(2+3) and 3/(2+3) of
460-
(6-1) inches. The widths of columns (horiz) will be similarly
461-
determined. When aspect ratio is set, the total height (or width) will
461+
(6-1) inches. The widths of the horizontal columns will be similarly
462+
determined. When the aspect ratio is set, the total height (or width) will
462463
be adjusted accordingly.
463464
464465
465466
The :mod:`mpl_toolkits.axes_grid1.axes_size` contains several classes
466467
that can be used to set the horizontal and vertical configurations. For
467-
example, for the vertical configuration above will be::
468+
example, for vertical configuration one could use::
468469
469470
from mpl_toolkits.axes_grid1.axes_size import Fixed, Scaled
470471
vert = [Fixed(2), Scaled(2), Scaled(3)]
471472
472473
After you set up the divider object, then you create a locator
473-
instance which will be given to the axes.::
474+
instance that will be given to the axes object.::
474475
475476
locator = divider.new_locator(nx=0, ny=1)
476477
ax.set_axes_locator(locator)
477478
478-
The return value of the new_locator method is a instance of the
479+
The return value of the new_locator method is an instance of the
479480
AxesLocator class. It is a callable object that returns the
480481
location and size of the cell at the first column and the second row.
481482
You may create a locator that spans over multiple cells.::
482483
483484
locator = divider.new_locator(nx=0, nx=2, ny=1)
484485
485486
The above locator, when called, will return the position and size of
486-
the cells spanning the first and second column and the first row. You
487-
may consider it as [0:2, 1].
487+
the cells spanning the first and second column and the first row. In
488+
this example, it will return [0:2, 1].
488489
489490
See the example,
490491
@@ -495,8 +496,8 @@
495496
496497
Simple Axes Divider2
497498
498-
You can adjust the size of the each axes according to their x or y
499-
data limits (AxesX and AxesY), similar to the axes aspect parameter.
499+
You can adjust the size of each axes according to its x or y
500+
data limits (AxesX and AxesY).
500501
501502
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_simple_axes_divider3_001.png
502503
:target: ../../gallery/axes_grid1/simple_axes_divider3.html

tutorials/toolkits/axisartist.py

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010
(derived from the mpl's original Axes class).
1111
As a side effect, some commands (mostly tick-related) do not work.
1212
13-
The *axisartist* contains custom Axes class that is meant to support for
13+
The *axisartist* contains a custom Axes class that is meant to support
1414
curvilinear grids (e.g., the world coordinate system in astronomy).
1515
Unlike mpl's original Axes class which uses Axes.xaxis and Axes.yaxis
16-
to draw ticks, ticklines and etc., Axes in axisartist uses special
17-
artist (AxisArtist) which can handle tick, ticklines and etc. for
16+
to draw ticks, ticklines, etc., axisartist uses a special
17+
artist (AxisArtist) that can handle ticks, ticklines, etc. for
1818
curved coordinate systems.
1919
2020
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_floating_axis_001.png
@@ -24,29 +24,29 @@
2424
2525
Demo Floating Axis
2626
27-
Since it uses special artists, some mpl commands that work on
27+
Since it uses special artists, some Matplotlib commands that work on
2828
Axes.xaxis and Axes.yaxis may not work.
2929
3030
.. _axisartist_users-guide-index:
3131
3232
axisartist
3333
==========
3434
35-
*axisartist* module provides a custom (and very experimental) Axes
36-
class, where each axis (left, right, top and bottom) have a separate
37-
associated artist which is responsible to draw axis-line, ticks,
38-
ticklabels, label. Also, you can create your own axis, which can pass
35+
The *axisartist* module provides a custom (and very experimental) Axes
36+
class, where each axis (left, right, top, and bottom) have a separate
37+
associated artist which is responsible for drawing the axis-line, ticks,
38+
ticklabels, and labels. You can also create your own axis, which can pass
3939
through a fixed position in the axes coordinate, or a fixed position
4040
in the data coordinate (i.e., the axis floats around when viewlimit
4141
changes).
4242
4343
The axes class, by default, has its xaxis and yaxis invisible, and
44-
has 4 additional artists which are responsible for drawing the 4 axis sides in
45-
"left","right","bottom" and "top". They are accessed as
44+
has 4 additional artists which are responsible for drawing the 4 axis spines in
45+
"left", "right", "bottom", and "top". They are accessed as
4646
ax.axis["left"], ax.axis["right"], and so on, i.e., ax.axis is a
4747
dictionary that contains artists (note that ax.axis is still a
48-
callable methods and it behaves as an original Axes.axis method in
49-
mpl).
48+
callable method and it behaves as an original Axes.axis method in
49+
Matplotlib).
5050
5151
To create an axes, ::
5252
@@ -60,7 +60,7 @@
6060
ax = AA.Subplot(fig, 111)
6161
fig.add_subplot(ax)
6262
63-
For example, you can hide the right, and top axis by ::
63+
For example, you can hide the right and top spines using::
6464
6565
ax.axis["right"].set_visible(False)
6666
ax.axis["top"].set_visible(False)
@@ -74,7 +74,7 @@
7474
Simple Axisline3
7575
7676
77-
It is also possible to add an extra axis. For example, you may have an
77+
It is also possible to add a horizontal axis. For example, you may have an
7878
horizontal axis at y=0 (in data coordinate). ::
7979
8080
ax.axis["y=0"] = ax.new_floating_axis(nth_coord=0, value=0)
@@ -98,8 +98,8 @@
9898
axisartist with ParasiteAxes
9999
----------------------------
100100
101-
Most commands in the axes_grid1 toolkit can take a axes_class keyword
102-
argument, and the commands creates an axes of the given class. For example,
101+
Most commands in the axes_grid1 toolkit can take an axes_class keyword
102+
argument, and the commands create an axes of the given class. For example,
103103
to create a host subplot with axisartist.Axes, ::
104104
105105
import mpl_toolkits.axisartist as AA
@@ -108,7 +108,7 @@
108108
host = host_subplot(111, axes_class=AA.Axes)
109109
110110
111-
Here is an example that uses parasiteAxes.
111+
Here is an example that uses parasiteAxes.
112112
113113
114114
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_parasite_axes2_001.png
@@ -123,7 +123,7 @@
123123
Curvilinear Grid
124124
----------------
125125
126-
The motivation behind the AxisArtist module is to support curvilinear grid
126+
The motivation behind the AxisArtist module is to support a curvilinear grid
127127
and ticks.
128128
129129
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_curvelinear_grid_001.png
@@ -137,7 +137,7 @@
137137
Floating Axes
138138
-------------
139139
140-
This also support a Floating Axes whose outer axis are defined as
140+
AxisArtist also supports a Floating Axes whose outer axes are defined as
141141
floating axis.
142142
143143
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_floating_axes_001.png

0 commit comments

Comments
 (0)