8000 Merge branch 'cgohlke_misc' of https://github.com/mdboom/matplotlib-p… · matplotlib/matplotlib@f22f485 · GitHub
[go: up one dir, main page]

Skip to content

Commit f22f485

Browse files
Merge branch 'cgohlke_misc' of https://github.com/mdboom/matplotlib-py3 into mdboom-cgohlke_misc
2 parents 25b6910 + 4ce5aec commit f22f485

File tree

6 files changed

+7
-7
lines changed

6 files changed

+7
-7
lines changed

examples/animation/simple_3danim.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ def Gen_RandLine(length, dims=2) :
1515
"""
1616
lineData = np.empty((dims, length))
1717
lineData[:, 0] = np.random.rand(dims)
18-
for index in xrange(1, length) :
18+
for index in range(1, length) :
1919
# scaling the random numbers by 0.1 so
2020
# movement is small compared to position.
2121
# subtraction by 0.5 is to change the range to [-0.5, 0.5]

examples/event_handling/viewlims.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def __call__(self, xstart, xend, ystart, yend):
3030
threshold_time = np.zeros((self.height, self.width))
3131
z = np.zeros(threshold_time.shape, dtype=np.complex)
3232
mask = np.ones(threshold_time.shape, dtype=np.bool)
33-
for i in xrange(self.niter):
33+
for i in range(self.niter):
3434
z[mask] = z[mask]**self.power + c[mask]
3535
mask = (np.abs(z) < self.radius)
3636
threshold_time += mask

examples/misc/multiprocess.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ def plot(self, finished=False):
8181

8282
def main():
8383
pl = NBPlot()
84-
for ii in xrange(10):
84+
for ii in range(10):
8585
pl.plot()
8686
time.sleep(0.5)
8787
raw_input('press Enter...')

examples/pylab_examples/scatter_star_poly.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
plt.scatter(x,y,s=80, c=z, marker=(5,0))
1414

1515
verts = list(zip([-1.,1.,1.,-1.],[-1.,-1.,1.,-1.]))
16-
pylab.subplot(323)
17-
pylab.scatter(x,y,s=80, c=z, marker=(verts,0))
16+
plt.subplot(323)
17+
plt.scatter(x,y,s=80, c=z, marker=(verts,0))
1818
# equivalent:
1919
#plt.scatter(x,y,s=80, c=z, marker=None, verts=verts)
2020

examples/pylab_examples/simple_plot_fps.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
frames = 100.0
2525
t = time.time()
2626
c = time.clock()
27-
for i in xrange(int(frames)):
27+
for i in range(int(frames)):
2828
part = i / frames
2929
axis([0.0, 1.0 - part, -1.0 + part, 1.0 - part])
3030
wallclock = time.time() - t

examples/user_interfaces/embedding_in_qt.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def compute_initial_figure(self):
7676

7777
def update_figure(self):
7878
# Build a list of 4 random integers between 0 and 10 (both inclusive)
79-
l = [ random.randint(0, 10) for i in xrange(4) ]
79+
l = [ random.randint(0, 10) for i in range(4) ]
8080

8181
self.axes.plot([0, 1, 2, 3], l, 'r')
8282
self.draw()

0 commit comments

Comments
 (0)
0