Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

PEP8 fixes.

  • Loading branch information...
commit f1450f34f91b5e841574765a17b086c051a1bd89 1 parent 588f0e2
@mdboom mdboom authored
Showing with 11 additions and 11 deletions.
  1. +10 −10 lib/matplotlib/axes.py
  2. +1 −1  lib/matplotlib/tests/test_axes.py
View
20 lib/matplotlib/axes.py
@@ -5443,7 +5443,7 @@ def errorbar(self, x, y, yerr=None, xerr=None,
lines_kw['transform'] = kwargs['transform']
if 'zorder' in kwargs:
lines_kw['zorder'] = kwargs['zorder']
-
+
# arrays fine here, they are booleans and hence not units
if not iterable(lolims):
lolims = np.asarray([lolims]*len(x), bool)
@@ -6442,28 +6442,28 @@ def hexbin(self, x, y, C = None, gridsize = 100, bins = None,
if xscale == 'log' or yscale == 'log':
polygons = np.expand_dims(polygon, 0) + np.expand_dims(offsets, 1)
if xscale == 'log':
- polygons[:,:,0] = 10.0 ** polygons[:,:,0]
+ polygons[:, :, 0] = 10.0 ** polygons[:, :, 0]
xmin = 10.0 ** xmin
xmax = 10.0 ** xmax
self.set_xscale(xscale)
if yscale == 'log':
- polygons[:,:,1] = 10.0 ** polygons[:,:,1]
+ polygons[:, :, 1] = 10.0 ** polygons[:, :, 1]
ymin = 10.0 ** ymin
ymax = 10.0 ** ymax
self.set_yscale(yscale)
collection = mcoll.PolyCollection(
polygons,
- edgecolors = edgecolors,
- linewidths = linewidths,
+ edgecolors=edgecolors,
+ linewidths=linewidths,
)
else:
collection = mcoll.PolyCollection(
[polygon],
- edgecolors = edgecolors,
- linewidths = linewidths,
- offsets = offsets,
- transOffset = mtransforms.IdentityTransform(),
- offset_position = "data"
+ edgecolors=edgecolors,
+ linewidths=linewidths,
+ offsets=offsets,
+ transOffset=mtransforms.IdentityTransform(),
+ offset_position="data"
)
if isinstance(norm, mcolors.LogNorm):
View
2  lib/matplotlib/tests/test_axes.py
@@ -431,7 +431,7 @@ def test_hexbin_log():
y = 2.0 + 3.0 * x + 4.0 * np.random.standard_normal(n)
y = np.power(2, y * 0.5)
ax = fig.add_subplot(111)
- plt.hexbin(x,y,yscale='log')
+ ax.hexbin(x, y, yscale='log')
@cleanup
def test_inverted_limits():
Please sign in to comment.
Something went wrong with that request. Please try again.