Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
ticker.LinearLocator view_limits algorithm improvement closes #6142 #6146
Conversation
mdboom
added the
needs_review
label
Mar 11, 2016
maqifrnswa
referenced
this pull request
Mar 11, 2016
Closed
matplotlib.ticker.LinearLocator view_limits algorithm improvement? #6142
tacaswell
added this to the
2.0 (style change major release)
milestone
Mar 12, 2016
|
attn @mdboom The conditions where this applies are a) if This is technically an API break, but could be convinced this is enough of a corner case / no one really wants the old behavior to let it slide. @maqifrnswa Can you add some before/after example of what this looks like? |
tacaswell
modified the milestone: 2.1 (next point release), 2.0 (style change major release)
Mar 14, 2016
|
How did you end up using I played with this a bit and could not see that this was clearly better than the current behavior. Pushing this off to 2.1 as it is not a blocking issue for 2.0. Can you provide some before/after examples and add a note to the |
|
The use case is for lining up the grid lines of a plot with two y-axis. When you are using References with example figures: http://stackoverflow.com/questions/20243683/matplotlib-align-twinx-tick-marks |
|
Ah, that use case is compelling. Can you give any examples of data ranges where this makes a big difference? This needs a rebase at any rate. |
|
Do you think twinx plots should default to this proposed linearlocator? To show examples of data ranges where this makes a difference, here's a script to generate lists of tick locations versus numticks and data size: Here is for sample ranges of 20-90 and numticks from 3 to 11 numticks: 12, data min: 20, data max: 90 numticks: 10, data min: 20, data max: 90 numticks: 9, data min: 20, data max: 90 numticks: 8, data min: 20, data max: 90 numticks: 7, data min: 20, data max: 90 numticks: 6, data min: 20, data max: 90 numticks: 5, data min: 20, data max: 90 numticks: 4, data min: 20, data max: 90 numticks: 3, data min: 20, data max: 90 Finally, no change if you use the current default number of ticks: |
|
On 2016/03/29 10:34 AM, Scott Howard wrote:
I think the way to expose it should be not as a default, but via kwargs |
|
I like it (and even understand the implementation now!). Given that this is an API break but not strictly a new feature, I think this should be pulled into v2.x. The choice of |
tacaswell
modified the milestone: 2.0 (style change major release), 2.1 (next point release)
Apr 30, 2016
tacaswell
merged commit 6bed1be
into matplotlib:master
May 4, 2016
tacaswell
removed the
needs_review
label
May 4, 2016
|
@maqifrnswa Can you do the twinx/twiny changes in a follow up PR? |
I'm a bit confused; one side says 2.0, the other says 2.1. |
|
Oops, I meant to refer to #6142 there. No backports noted just yet. |
|
I think this should be back ported to 2.x. On Wed, May 4, 2016, 03:27 Elliott Sales de Andrade <
|
|
I don't think this was backported... |
tacaswell
added a commit
that referenced
this pull request
May 13, 2016
|
|
tacaswell |
e785afb
|
|
(finally) backported to v2.x as e785afb |
|
@QuLogic Thanks for keeping track of this! |
maqifrnswa commentedMar 11, 2016
No description provided.