Menu

[r612]: / trunk / htdocs / screenshots / polar_demo.py  Maximize  Restore  History

Download this file

19 lines (15 with data), 545 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
#!/usr/bin/env python
from matplotlib.matlab import *
# radar green, solid grid lines
rc('grid', color='#316931', linewidth=1, linestyle='-')
rc('tick', labelsize=15)
# force square figure and square axes looks better for polar, IMO
figure(figsize=(8,8))
ax = axes([0.1, 0.1, 0.8, 0.8], polar=True, axisbg='#d5de9c')
r = arange(0,1,0.001)
theta = 2*2*pi*r
polar(theta, r, color='#ee8d18', lw=3)
set(ax.thetagridlabels, y=1.075) # the radius of the grid labels
title("And there was much rejoicing!", fontsize=20)
#savefig('polar_demo')
show()
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.