Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 7b35de2

Browse files
committed
pep8 changes
1 parent a7bfef2 commit 7b35de2

File tree

1 file changed

+7
-19
lines changed

1 file changed

+7
-19
lines changed

examples/pylab_examples/quiver_demo.py

Lines changed: 7 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -56,17 +56,11 @@
5656
# 4
5757
plt.figure()
5858
M = np.sqrt(np.power(U, 2) + np.power(V, 2))
59-
Q = plt.quiver(
60-
X,
61-
Y,
62-
U,
63-
V,
64-
M,
65-
units='x',
66-
pivot='tip',
67-
width=0.022,
68-
scale=1 /
69-
0.15)
59+
Q = plt.quiver(X, Y, U, V, M,
60+
units='x',
61+
pivot='tip',
62+
width=0.022,
63+
scale=1 / 0.15)
7064
qk = plt.quiverkey(Q, 0.9, 1.05, 1, r'$1 \frac{m}{s}$',
7165
labelpos='E',
7266
fontproperties={'weight': 'bold'})
@@ -79,14 +73,8 @@
7973
Q = plt.quiver(X[::3, ::3], Y[::3, ::3], U[::3, ::3], V[::3, ::3],
8074
color='r', units='x',
8175
linewidths=(2,), edgecolors=('k'), headaxislength=5)
82-
qk = plt.quiverkey(
83-
Q,
84-
0.5,
85-
0.03,
86-
1,
87-
r'$1 \frac{m}{s}$',
88-
fontproperties={
89-
'weight': 'bold'})
76+
qk = plt.quiverkey(Q, 0.5, 0.03, 1, r'$1 \frac{m}{s}$',
77+
fontproperties={'weight': 'bold'})
9078
plt.axis([-1, 7, -1, 7])
9179
plt.title("triangular head; scale with x view; black edges")
9280

0 commit comments

Comments
 (0)