8000 Merge pull request #6688 from afvincent/fix_polar_scatter_demo · matplotlib/matplotlib@70b851f · GitHub
[go: up one dir, main page]

Skip to content

Commit 70b851f

Browse files
NelleVQuLogic
authored andcommitted
Merge pull request #6688 from afvincent/fix_polar_scatter_demo
DOC: fix radial increase of size & OO style in polar_scatter_demo
1 parent b04c5b9 commit 70b851f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
"""
22
Demo of scatter plot on a polar axis.
33
4-
Size increases radially in this example and color increases with angle (just to
5-
verify the symbols are being scattered correctly).
4+
Size increases radially in this example and color increases with angle
5+
(just to verify the symbols are being scattered correctly).
66
"""
77
import numpy as np
88
import matplotlib.pyplot as plt
@@ -11,11 +11,11 @@
1111
N = 150
1212
r = 2 * np.random.rand(N)
1313
theta = 2 * np.pi * np.random.rand(N)
14-
area = 200 * r**2 * np.random.rand(N)
14+
area = 200 * r**2
1515
colors = theta
1616

1717
ax = plt.subplot(111, projection='polar')
18-
c = plt.scatter(theta, r, c=colors, s=area, cmap=plt.cm.hsv)
18+
c = ax.scatter(theta, r, c=colors, s=area, cmap=plt.cm.hsv)
1919
c.< 3BBA span class=pl-c1>set_alpha(0.75)
2020

2121
plt.show()

0 commit comments

Comments
 (0)
0