Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 8a810fa

Browse filesBrowse files
committed
style fixes
1 parent 9231c4c commit 8a810fa
Copy full SHA for 8a810fa
Expand file treeCollapse file tree

12 files changed

+26
-19
lines changed

‎examples/mplot3d/contour3d_demo.py

Copy file name to clipboardExpand all lines: examples/mplot3d/contour3d_demo.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
fig = plt.figure()
66
ax = fig.add_subplot(111, projection='3d')
77
X, Y, Z = axes3d.get_test_data(0.05)
8-
cset = ax.contour(X, Y, Z, cmap = cm.coolwarm)
8+
cset = ax.contour(X, Y, Z, cmap=cm.coolwarm)
99
ax.clabel(cset, fontsize=9, inline=1)
1010

1111
plt.show()

‎examples/mplot3d/contour3d_demo2.py

Copy file name to clipboardExpand all lines: examples/mplot3d/contour3d_demo2.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
fig = plt.figure()
66
ax = fig.gca(projection='3d')
77
X, Y, Z = axes3d.get_test_data(0.05)
8-
cset = ax.contour(X, Y, Z, extend3d=True, cmap = cm.coolwarm)
8+
cset = ax.contour(X, Y, Z, extend3d=True, cmap=cm.coolwarm)
99
ax.clabel(cset, fontsize=9, inline=1)
1010

1111
plt.show()

‎examples/mplot3d/contour3d_demo3.py

Copy file name to clipboardExpand all lines: examples/mplot3d/contour3d_demo3.py
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
ax = fig.gca(projection='3d')
77
X, Y, Z = axes3d.get_test_data(0.05)
88
ax.plot_surface(X, Y, Z, rstride=8, cstride=8, alpha=0.3)
9-
cset = ax.contour(X, Y, Z, zdir='z', offset=-100, cmap = cm.coolwarm)
10-
cset = ax.contour(X, Y, Z, zdir='x', offset=-40, cmap = cm.coolwarm)
11-
cset = ax.contour(X, Y, Z, zdir='y', offset=40, cmap = cm.coolwarm)
9+
cset = ax.contour(X, Y, Z, zdir='z', offset=-100, cmap=cm.coolwarm)
10+
cset = ax.contour(X, Y, Z, zdir='x', offset=-40, cmap=cm.coolwarm)
11+
cset = ax.contour(X, Y, Z, zdir='y', offset=40, cmap=cm.coolwarm)
1212

1313
ax.set_xlabel('X')
1414
ax.set_xlim(-40, 40)

‎examples/mplot3d/contourf3d_demo.py

Copy file name to clipboardExpand all lines: examples/mplot3d/contourf3d_demo.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
fig = plt.figure()
66
ax = fig.gca(projection='3d')
77
X, Y, Z = axes3d.get_test_data(0.05)
8-
cset = ax.contourf(X, Y, Z, cmap = cm.coolwarm)
8+
cset = ax.contourf(X, Y, Z, cmap=cm.coolwarm)
99
ax.clabel(cset, fontsize=9, inline=1)
1010

1111
plt.show()

‎examples/mplot3d/contourf3d_demo2.py

Copy file name to clipboardExpand all lines: examples/mplot3d/contourf3d_demo2.py
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
ax = fig.gca(projection='3d')
1212
X, Y, Z = axes3d.get_test_data(0.05)
1313
ax.plot_surface(X, Y, Z, rstride=8, cstride=8, alpha=0.3)
14-
cset = ax.contourf(X, Y, Z, zdir='z', offset=-100, cmap = cm.coolwarm)
15-
cset = ax.contourf(X, Y, Z, zdir='x', offset=-40, cmap = cm.coolwarm)
16-
cset = ax.contourf(X, Y, Z, zdir='y', offset=40, cmap = cm.coolwarm)
14+
cset = ax.contourf(X, Y, Z, zdir='z', offset=-100, cmap=cm.coolwarm)
15+
cset = ax.contourf(X, Y, Z, zdir='x', offset=-40, cmap=cm.coolwarm)
16+
cset = ax.contourf(X, Y, Z, zdir='y', offset=40, cmap=cm.coolwarm)
1717

1818
ax.set_xlabel('X')
1919
ax.set_xlim(-40, 40)

‎examples/pylab_examples/contourf_log.py

Copy file name to clipboardExpand all lines: examples/pylab_examples/contourf_log.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030

3131
# Automatic selection of levels works; setting the
3232
# log locator tells contourf to use a log scale:
33-
cs = P.contourf(X, Y, z, locator=ticker.LogLocator(), cmap = cm.PuBu_r)
33+
cs = P.contourf(X, Y, z, locator=ticker.LogLocator(), cmap=cm.PuBu_r)
3434

3535
# Alternatively, you can manually set the levels
3636
# and the norm:

‎examples/pylab_examples/griddata_demo.py

Copy file name to clipboardExpand all lines: examples/pylab_examples/griddata_demo.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616
zi = griddata(x,y,z,xi,yi,interp='linear')
1717
# contour the gridded data, plotting dots at the nonuniform data points.
1818
CS = plt.contour(xi,yi,zi,15,linewidths=0.5,colors='k')
19-
CS = plt.contourf(xi,yi,zi,15,cmap=plt.cm.rainbow, vmax=abs(zi).max(), vmin=-abs(zi).max())
19+
CS = plt.contourf(xi,yi,zi,15,cmap=plt.cm.rainbow,
20+
vmax=abs(zi).max(), vmin=-abs(zi).max())
2021
plt.colorbar() # draw colorbar
2122
# plot data points.
2223
plt.scatter(x,y,marker='o',c='b',s=5,zorder=10)

‎examples/pylab_examples/hexbin_demo2.py

Copy file name to clipboardExpand all lines: examples/pylab_examples/hexbin_demo2.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@
3939
gridsize=30
4040

4141
plt.subplot(211)
42-
plt.hexbin(x,y, C=z, gridsize=gridsize, marginals=True, cmap=plt.cm.RdBu, vmax=abs(z).max(), vmin=-abs(z).max())
42+
plt.hexbin(x,y, C=z, gridsize=gridsize, marginals=True, cmap=plt.cm.RdBu,
43+
vmax=abs(z).max(), vmin=-abs(z).max())
4344
plt.axis([xmin, xmax, ymin, ymax])
4445
cb = plt.colorbar()
4546
cb.set_label('mean value')

‎examples/pylab_examples/poormans_contour.py

Copy file name to clipboardExpand all lines: examples/pylab_examples/poormans_contour.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@
2020

2121
cmap = cm.get_cmap('PiYG', 11) # 11 discrete colors
2222

23-
im = imshow(Z, cmap=cmap, interpolation='bilinear', vmax=abs(Z).max(), vmin=-abs(Z).max())
23+
im = imshow(Z, cmap=cmap, interpolation='bilinear',
24+
vmax=abs(Z).max(), vmin=-abs(Z).max())
2425
axis('off')
2526
colorbar()
2627

‎examples/pylab_examples/specgram_demo.py

Copy file name to clipboardExpand all lines: examples/pylab_examples/specgram_demo.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,5 +25,6 @@
2525
ax1 = subplot(211)
2626
plot(t, x)
2727
subplot(212, sharex=ax1)
28-
Pxx, freqs, bins, im = specgram(x, NFFT=NFFT, Fs=Fs, noverlap=900, cmap=cm.gist_heat)
28+
Pxx, freqs, bins, im = specgram(x, NFFT=NFFT, Fs=Fs, noverlap=900,
29+
cmap=cm.gist_heat)
2930
show()

‎examples/pylab_examples/tricontour_vs_griddata.py

Copy file name to clipboardExpand all lines: examples/pylab_examples/tricontour_vs_griddata.py
+4-2Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@
2424
yi = np.linspace(-2.1,2.1,ngridy)
2525
zi = griddata(x,y,z,xi,yi,interp='linear')
2626
plt.contour(xi,yi,zi,15,linewidths=0.5,colors='k')
27-
plt.contourf(xi,yi,zi,15,cmap=plt.cm.rainbow, norm=plt.normalize(vmax=abs(zi).max(), vmin=-abs(zi).max()))
27+
plt.contourf(xi,yi,zi,15,cmap=plt.cm.rainbow,
28+
norm=plt.normalize(vmax=abs(zi).max(), vmin=-abs(zi).max()))
2829
plt.colorbar() # draw colorbar
2930
plt.plot(x, y, 'ko', ms=3)
3031
plt.xlim(-2,2)
@@ -37,7 +38,8 @@
3738
plt.subplot(212)
3839
triang = tri.Triangulation(x, y)
3940
plt.tricontour(x, y, z, 15, linewidths=0.5, colors='k')
40-
plt.tricontourf(x, y, z, 15, cmap=plt.cm.rainbow, norm=plt.normalize(vmax=abs(zi).max(), vmin=-abs(zi).max()))
41+
plt.tricontourf(x, y, z, 15, cmap=plt.cm.rainbow,
42+
norm=plt.normalize(vmax=abs(zi).max(), vmin=-abs(zi).max()))
4143
plt.colorbar()
4244
plt.plot(x, y, 'ko', ms=3)
4345
plt.xlim(-2,2)

‎examples/pylab_examples/tripcolor_demo.py

Copy file name to clipboardExpand all lines: examples/pylab_examples/tripcolor_demo.py
+4-3Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,14 @@
3535
# pcolor plot.
3636
plt.figure()
3737
plt.gca().set_aspect('equal')
38-
plt.tripcolor(triang, z, shading='flat', cmap = plt.cm.rainbow)
38+
plt.tripcolor(triang, z, shading='flat', cmap=plt.cm.rainbow)
3939
plt.colorbar()
4040
plt.title('tripcolor of Delaunay triangulation: flat')
4141

4242
# Illustrate Gouraud shading.
4343
plt.figure()
4444
plt.gca().set_aspect('equal')
45-
plt.tripcolor(triang, z, shading='gouraud', cmap = plt.cm.rainbow)
45+
plt.tripcolor(triang, z, shading='gouraud', cmap=plt.cm.rainbow)
4646
plt.colorbar()
4747
plt.title('tripcolor with Gouraud shading')
4848

@@ -96,7 +96,8 @@
9696
# calculations.
9797
plt.figure()
9898
plt.gca().set_aspect('equal')
99-
plt.tripcolor(x, y, triangles, z, shading='flat', edgecolors='k', cmap = cm.summer)
99+
plt.tripcolor(x, y, triangles, z, shading='flat', edgecolors='k',
100+
cmap=cm.summer)
100101
plt.colorbar()
101102
plt.title('tripcolor of user-specified triangulation')
102103
plt.xlabel('Longitude (degrees)')

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.