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

Skip to content

Commit c0891d1

Browse files
committed
doc: Plot something on polar axes in subplots demo.
1 parent 7a0647f commit c0891d1

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

examples/pylab_examples/subplots_demo.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,16 @@
6666
plt.setp([a.get_yticklabels() for a in axarr[:, 1]], visible=False)
6767

6868
# Four polar axes
69-
plt.subplots(2, 2, subplot_kw=dict(projection='polar'))
69+
f, axarr = plt.subplots(2, 2, subplot_kw=dict(projection='polar'))
70+
axarr[0, 0].plot(x, y)
71+
axarr[0, 0].set_title('Axis [0,0]')
72+
axarr[0, 1].scatter(x, y)
73+
axarr[0, 1].set_title('Axis [0,1]')
74+
axarr[1, 0].plot(x, y ** 2)
75+
axarr[1, 0].set_title('Axis [1,0]')
76+
axarr[1, 1].scatter(x, y ** 2)
77+
axarr[1, 1].set_title('Axis [1,1]')
78+
# Fine-tune figure; make subplots farther from each other.
79+
f.subplots_adjust(hspace=0.3)
7080

7181
plt.show()

0 commit comments

Comments
 (0)