Skip to content

Commit

Permalink
DOC/PEP8 : details related to PR matplotlib#3433
Browse files Browse the repository at this point in the history
  • Loading branch information
tacaswell committed Oct 19, 2014
1 parent e7717f7 commit e55008e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
5 changes: 5 additions & 0 deletions doc/users/whats_new/plotting.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Added center and frame kwargs to pie
````````````````````````````````````

These control where the center of the pie graph are and if
the Axes frame is shown.
7 changes: 3 additions & 4 deletions lib/matplotlib/tests/test_axes.py
Original file line number Diff line number Diff line change
Expand Up @@ -3398,21 +3398,20 @@ def test_pie_frame_grid():
# only "explode" the 2nd slice (i.e. 'Hogs')
explode = (0, 0.1, 0, 0)


plt.pie(sizes, explode=explode, labels=labels, colors=colors,
autopct='%1.1f%%', shadow=True, startangle=90,
wedgeprops={'linewidth': 0},
frame=True, center=(2,2))
frame=True, center=(2, 2))

plt.pie(sizes[::-1], explode=explode, labels=labels, colors=colors,
autopct='%1.1f%%', shadow=True, startangle=90,
wedgeprops={'linewidth': 0},
frame=True, center=(5,2))
frame=True, center=(5, 2))

plt.pie(sizes, explode=explode[::-1], labels=labels, colors=colors,
autopct='%1.1f%%', shadow=True, startangle=90,
wedgeprops={'linewidth': 0},
frame=True, center=(3,5))
frame=True, center=(3, 5))
# Set aspect ratio to be equal so that pie is drawn as a circle.
plt.axis('equal')

Expand Down

0 comments on commit e55008e

Please sign in to comment.