Skip to content

Commit 6fd6220

Browse files
authored
Merge pull request rougier#7 from jruota/master
Add edges in the pie chart exercise
2 parents f0f6e08 + 449e279 commit 6fd6220

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

scripts/pie_ex.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@
99
Z = np.ones(n)
1010
Z[-1] *= 2
1111

12-
plt.axes([0.025,0.025,0.95,0.95])
12+
plt.axes([0.025, 0.025, 0.95, 0.95])
1313

14-
plt.pie(Z, explode=Z*.05, colors = ['%f' % (i/float(n)) for i in range(n)])
14+
plt.pie(Z, explode=Z*.05, colors=['%f' % (i/float(n)) for i in range(n)],
15+
wedgeprops={"linewidth": 1, "edgecolor": "black"})
1516
plt.gca().set_aspect('equal')
1617
plt.xticks([]), plt.yticks([])
1718

0 commit comments

Comments
 (0)