From 8cde3c8c7f1cc5752b785278eb2fd0252b6c52bb Mon Sep 17 00:00:00 2001 From: Eric Ma Date: Fri, 7 Aug 2015 13:04:49 -0400 Subject: [PATCH 1/2] mep12 on manual_axis.py --- examples/pylab_examples/manual_axis.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/pylab_examples/manual_axis.py b/examples/pylab_examples/manual_axis.py index feaf4556a154..3bd536a4a7a4 100644 --- a/examples/pylab_examples/manual_axis.py +++ b/examples/pylab_examples/manual_axis.py @@ -5,11 +5,11 @@ This example should be considered deprecated and is left just for demo purposes for folks wanting to make a pseudo-axis - """ import numpy as np -from pylab import figure, show +# from pylab import figure, show +import matplotlib.pyplot as plt import matplotlib.lines as lines @@ -47,7 +47,7 @@ def make_yaxis(ax, xloc=0, offset=0.05, **props): props = dict(color='black', linewidth=2, markeredgewidth=2) x = np.arange(200.) y = np.sin(2*np.pi*x/200.) + np.random.rand(200) - 0.5 -fig = figure(facecolor='white') +fig = plt.figure(facecolor='white') ax = fig.add_subplot(111, frame_on=False) ax.axison = False ax.plot(x, y, 'd', markersize=8, markerfacecolor='blue') @@ -56,4 +56,4 @@ def make_yaxis(ax, xloc=0, offset=0.05, **props): make_xaxis(ax, 0, offset=0.1, **props) make_yaxis(ax, 0, offset=5, **props) -show() +plt.show() From 21dfdffb7e1193b0d07b9f46c12b08d6f213d810 Mon Sep 17 00:00:00 2001 From: Eric Ma Date: Fri, 7 Aug 2015 13:09:17 -0400 Subject: [PATCH 2/2] removed pylab comment --- examples/pylab_examples/manual_axis.py | 1 - 1 file changed, 1 deletion(-) diff --git a/examples/pylab_examples/manual_axis.py b/examples/pylab_examples/manual_axis.py index 3bd536a4a7a4..f1f8b2aedc51 100644 --- a/examples/pylab_examples/manual_axis.py +++ b/examples/pylab_examples/manual_axis.py @@ -8,7 +8,6 @@ """ import numpy as np -# from pylab import figure, show import matplotlib.pyplot as plt import matplotlib.lines as lines