diff options
Diffstat (limited to 'numpy/lib/twodim_base.py')
-rw-r--r-- | numpy/lib/twodim_base.py | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/numpy/lib/twodim_base.py b/numpy/lib/twodim_base.py index 12c0f9bb3..8c99f6804 100644 --- a/numpy/lib/twodim_base.py +++ b/numpy/lib/twodim_base.py @@ -25,7 +25,7 @@ def fliplr(m): Parameters ---------- m : array_like - Input array. + Input array, must be at least 2-D. Returns ------- @@ -40,8 +40,7 @@ def fliplr(m): Notes ----- - Equivalent to A[:,::-1]. Does not require the array to be - two-dimensional. + Equivalent to A[:,::-1]. Requires the array to be at least 2-D. Examples -------- @@ -650,14 +649,14 @@ def histogram2d(x, y, bins=10, range=None, normed=False, weights=None): >>> fig = plt.figure(figsize=(7, 3)) >>> ax = fig.add_subplot(131) - >>> ax.set_title('imshow:\nequidistant') + >>> ax.set_title('imshow: equidistant') >>> im = plt.imshow(H, interpolation='nearest', origin='low', extent=[xedges[0], xedges[-1], yedges[0], yedges[-1]]) pcolormesh can display exact bin edges: >>> ax = fig.add_subplot(132) - >>> ax.set_title('pcolormesh:\nexact bin edges') + >>> ax.set_title('pcolormesh: exact bin edges') >>> X, Y = np.meshgrid(xedges, yedges) >>> ax.pcolormesh(X, Y, H) >>> ax.set_aspect('equal') @@ -665,7 +664,7 @@ def histogram2d(x, y, bins=10, range=None, normed=False, weights=None): NonUniformImage displays exact bin edges with interpolation: >>> ax = fig.add_subplot(133) - >>> ax.set_title('NonUniformImage:\ninterpolated') + >>> ax.set_title('NonUniformImage: interpolated') >>> im = mpl.image.NonUniformImage(ax, interpolation='bilinear') >>> xcenters = xedges[:-1] + 0.5 * (xedges[1:] - xedges[:-1]) >>> ycenters = yedges[:-1] + 0.5 * (yedges[1:] - yedges[:-1]) |