Skip to content

Commit 50381be

Browse files
committed
Fix a bunch of warnings in the documentation build
1 parent 7085dad commit 50381be

File tree

7 files changed

+35
-28
lines changed

7 files changed

+35
-28
lines changed

doc/faq/howto_faq.rst

+6-5
Original file line numberDiff line numberDiff line change
@@ -529,10 +529,12 @@ important for complex figures that take some time to draw.
529529
you're all done issuing commands and you want to draw the figure now.
530530

531531
.. note::
532-
:func:`~matplotlib.pyplot.show` should typically only be called
533-
at most once per script and it should be the last line of your script.
534-
At that point, the GUI takes control of the interpreter. If you want
535-
to force a figure draw, use :func:`~matplotlib.pyplot.draw` instead.
532+
533+
:func:`~matplotlib.pyplot.show` should typically only be called at
534+
most once per script and it should be the last line of your
535+
script. At that point, the GUI takes control of the interpreter.
536+
If you want to force a figure draw, use
537+
:func:`~matplotlib.pyplot.draw` instead.
536538

537539
Many users are frustrated by ``show`` because they want it to be a
538540
blocking call that raises the figure, pauses the script until they
@@ -778,4 +780,3 @@ Engineering, Vol. 9, No. 3. (2007), pp. 90-95 (see `citeulike <http://www.citeul
778780
development, interactive scripting, and publication-quality image
779781
generation across user interfaces and operating systems.},
780782
Bdsk-Url-1 = {http://gateway.isiknowledge.com/gateway/Gateway.cgi?GWVersion=2&SrcAuth=Alerting&SrcApp=Alerting&DestApp=WOS&DestLinkType=FullRecord;KeyUT=000245668100019}}
781-

examples/api/logo2.py

+1-3
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ def add_matplotlib_text(ax):
4747
ha='right', va='center', alpha=1.0, transform=ax.transAxes)
4848

4949
def add_polar_bar():
50-
ax = fig.add_axes([0.025, 0.075, 0.2, 0.85], polar=True, resolution=50)
50+
ax = fig.add_axes([0.025, 0.075, 0.2, 0.85], polar=True)
5151

5252

5353
ax.axesPatch.set_alpha(axalpha)
@@ -79,5 +79,3 @@ def add_polar_bar():
7979
add_polar_bar()
8080
add_matplotlib_text(main_axes)
8181
plt.show()
82-
83-

lib/matplotlib/axes.py

+8-6
Original file line numberDiff line numberDiff line change
@@ -2728,7 +2728,7 @@ def set_yticks(self, ticks, minor=False):
27282728

27292729
def get_ymajorticklabels(self):
27302730
"""
2731-
Get the major y tick labels as a list of
2731+
Get the major y tick labels as a list of
27322732
:class:`~matplotlib.text.Text` instances.
27332733
"""
27342734
return cbook.silent_list('Text yticklabel',
@@ -7532,11 +7532,13 @@ def hist(x, bins=10, range=None, normed=False, weights=None,
75327532
pdf, bins, patches = ax.hist(...)
75337533
print np.sum(pdf * np.diff(bins))
75347534
7535-
.. Note:: Until numpy release 1.5, the underlying numpy
7536-
histogram function was incorrect with *normed*=*True*
7537-
if bin sizes were unequal. MPL inherited that
7538-
error. It is now corrected within MPL when using
7539-
earlier numpy versions
7535+
.. note::
7536+
7537+
Until numpy release 1.5, the underlying numpy
7538+
histogram function was incorrect with *normed*=*True*
7539+
if bin sizes were unequal. MPL inherited that
7540+
error. It is now corrected within MPL when using
7541+
earlier numpy versions
75407542
75417543
*weights*:
75427544
An array of weights, of the same shape as *x*. Each value in

lib/matplotlib/cbook.py

+1
Original file line numberDiff line numberDiff line change
@@ -936,6 +936,7 @@ def get_split_ind(seq, N):
936936
937937
len(' '.join(seq[:ind])<=N
938938
939+
.
939940
"""
940941

941942
sLen = 0

lib/matplotlib/transforms.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -1490,6 +1490,7 @@ def from_values(a, b, c, d, e, f):
14901490
b d f
14911491
0 0 1
14921492
1493+
.
14931494
"""
14941495
return Affine2D(
14951496
np.array([a, c, e, b, d, f, 0.0, 0.0, 1.0], np.float_)
@@ -1503,6 +1504,7 @@ def get_matrix(self):
15031504
b d f
15041505
0 0 1
15051506
1507+
.
15061508
"""
15071509
self._invalid = 0
15081510
return self._mtx
@@ -1515,6 +1517,7 @@ def set_matrix(self, mtx):
15151517
b d f
15161518
0 0 1
15171519
1520+
.
15181521
"""
15191522
self._mtx = mtx
15201523
self.invalidate()
@@ -2333,4 +2336,3 @@ def offset_copy(trans, fig=None, x=0.0, y=0.0, units='inches'):
23332336
elif not units == 'inches':
23342337
raise ValueError('units must be dots, points, or inches')
23352338
return trans + ScaledTranslation(x, y, fig.dpi_scale_trans)
2336-

lib/mpl_toolkits/axes_grid1/axes_divider.py

+8-6
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,8 @@ def set_horizontal(self, h):
153153
:param horizontal: list of sizes
154154
(:mod:`~mpl_toolkits.axes_grid.axes_size`)
155155
for horizontal division
156+
157+
.
156158
"""
157159
self._horizontal = h
158160

@@ -166,6 +168,8 @@ def set_vertical(self, v):
166168
:param horizontal: list of sizes
167169
(:mod:`~mpl_toolkits.axes_grid.axes_size`)
168170
for horizontal division
171+
172+
.
169173
"""
170174
self._vertical = v
171175

@@ -276,7 +280,7 @@ def append_size(self, position, size):
276280
raise ValueError("the position must be one of left, right, bottom, or top")
277281

278282

279-
def add_auto_adjustable_area(self,
283+
def add_auto_adjustable_area(self,
280284
use_axes, pad=0.1,
281285
adjust_dirs=["left", "right", "bottom", "top"],
282286
):
@@ -339,7 +343,7 @@ def get_subplotspec(self):
339343
return None
340344

341345

342-
346+
343347
from matplotlib.gridspec import SubplotSpec, GridSpec
344348

345349
class SubplotDivider(Divider):
@@ -919,10 +923,10 @@ def make_axes_locatable(axes):
919923

920924
return divider
921925

922-
def make_axes_area_auto_adjustable(ax,
926+
def make_axes_area_auto_adjustable(ax,
923927
use_axes=None, pad=0.1,
924928
adjust_dirs=["left", "right", "bottom", "top"]):
925-
929+
926930
divider = make_axes_locatable(ax)
927931

928932
if use_axes is None:
@@ -934,5 +938,3 @@ def make_axes_area_auto_adjustable(ax,
934938
#from matplotlib.axes import Axes
935939
from mpl_axes import Axes
936940
LocatableAxes = locatable_axes_factory(Axes)
937-
938-

lib/mpl_toolkits/mplot3d/axes3d.py

100644100755
+8-7
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ def __init__(self, fig, rect=None, *args, **kwargs):
8484

8585
# func used to format z -- fall back on major formatters
8686
self.fmt_zdata = None
87-
87+
8888
if zscale is not None :
8989
self.set_zscale(zscale)
9090

@@ -608,10 +608,10 @@ def set_zticks(self, *args, **kwargs):
608608
.. versionadded:: 1.1.0
609609
"""
610610
return self.zaxis.set_ticks(*args, **kwargs)
611-
611+
612612
def get_zticks(self, minor=False):
613613
"""
614-
Return the z ticks as a list of locations
614+
Return the z ticks as a list of locations
615615
See :meth:`matplotlib.axes.Axes.get_yticks` for more details.
616616
617617
.. note::
@@ -633,7 +633,7 @@ def get_zmajorticklabels(self) :
633633
def get_zminorticklabels(self) :
634634
"""
635635
Get the ztick labels as a list of Text instances
636-
636+
637637
.. note::
638638
Minor ticks are not supported. This function was added
639639
only for completeness.
@@ -1044,6 +1044,7 @@ def grid(self, b=True, **kwargs):
10441044
Set / unset 3D grid.
10451045
10461046
.. note::
1047+
10471048
Currently, this function does not behave the same as
10481049
:meth:`matplotlib.axes.Axes.grid`, but it is intended to
10491050
eventually support that behavior.
@@ -1359,7 +1360,7 @@ def plot_surface(self, X, Y, Z, *args, **kwargs):
13591360
# then an exception is automatically thrown.
13601361
X.shape = (rows, cols)
13611362
Y.shape = (rows, cols)
1362-
1363+
13631364
rstride = kwargs.pop('rstride', 10)
13641365
cstride = kwargs.pop('cstride', 10)
13651366

@@ -1395,7 +1396,7 @@ def plot_surface(self, X, Y, Z, *args, **kwargs):
13951396
#colset contains the data for coloring: either average z or the facecolor
13961397
colset = []
13971398
for rs in xrange(0, rows-1, rstride):
1398-
for cs in xrange(0, cols-1, cstride):
1399+
for cs in xrange(0, cols-1, cstride):
13991400
ps = []
14001401
for a in (X, Y, Z) :
14011402
ztop = a[rs,cs:min(cols, cs+cstride+1)]
@@ -2075,7 +2076,7 @@ def get_test_data(delta=0.05):
20752076

20762077

20772078
########################################################
2078-
# Register Axes3D as a 'projection' object available
2079+
# Register Axes3D as a 'projection' object available
20792080
# for use just like any other axes
20802081
########################################################
20812082
import matplotlib.projections as proj

0 commit comments

Comments
 (0)