| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
The implementation of shrink relies on scipy, which I do not believe we want to make a dependency for building the docs. See, for example, the double pendulum example which implements the code in python rather than using a scipy method which would provide better results. |
Sorry, something went wrong.
|
Good observation! (Should probably not approve stuff with a heavy cold...) It would be great to get rid of the scipy dependency. |
Sorry, something went wrong.
Would it be okay if the example uses "shrink=None" so that importing scipy is bypassed? |
Sorry, something went wrong.
|
I think the effect you are looking for can be had with library-native changes to the explode parameter rather than passing through scipy.ndimage. Here is a quick example demonstrating the differences between the example as is (with your fixes so that it works, but without shrink, with your shrink implementation and with no shrink, but a uniform 0.1 for explode rather than (0, 0.05, 0, 0) |
Sorry, something went wrong.
|
Okay, I have removed shrink parameter so the scipy dependency. However, I still think that it would be good to have a shrink parameter as it offers a rather general solution not specific to pie chart. I also have rebased the PR to the current main and force-pushed it. |
Sorry, something went wrong.
Thanks! |
Sorry, something went wrong.
Co-authored-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
There was a problem hiding this comment.
Sorry, something went wrong.
…261-on-v3.6.x Backport PR #24261 on branch v3.6.x (Fix pie chart in demo_agg_filter.py)
* fix demo_agg_filter.py * Update examples/misc/demo_agg_filter.py Co-authored-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
* fix demo_agg_filter.py * Update examples/misc/demo_agg_filter.py Co-authored-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
* fix demo_agg_filter.py * Update examples/misc/demo_agg_filter.py Co-authored-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
* fix demo_agg_filter.py * Update examples/misc/demo_agg_filter.py Co-authored-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
| Back | FazBrowse Home | New Git URL |
PR Summary
This fixes the pie chart in [demo_agg_filter.py] (https://matplotlib.org/stable/gallery/misc/demo_agg_filter.html) which is incorrectly displayed with simple black color . Fixed image is shown below. It also add new shrink parameter and a bit of more documentation.
PR Checklist
Tests and Styling
Documentation