Skip to content

Set maximum number of bins in ticking#5724

Merged
efiring merged 1 commit into
matplotlib:v2.xfrom
mdboom:tick-maximum
Jan 24, 2016
Merged

Set maximum number of bins in ticking#5724
efiring merged 1 commit into
matplotlib:v2.xfrom
mdboom:tick-maximum

Conversation

@mdboom

@mdboom mdboom commented Dec 22, 2015

Copy link
Copy Markdown
Member

Follow-on to #5588 based on @efiring's comment that now there can be too many ticks. (#5588 (comment))

@mdboom mdboom added this to the next major release (2.0) milestone Dec 22, 2015
@jenshnielsen

Copy link
Copy Markdown
Member

👍 I guess we can ignore the appveyor error?

@tacaswell

Copy link
Copy Markdown
Member

This interacts with #5772 in a safe way, but we should probably centralize this logic in one place or the other.

@WeatherGod

Copy link
Copy Markdown
Member

just thinking out loud, would it make sense to use a logarithm for the
number of bins? I am imagining edge cases where users want really long time
series. we have had users hitting limits in the agg renderer before with
very big plots.

On Thu, Dec 31, 2015 at 2:30 PM, Thomas A Caswell [email protected]
wrote:

This interacts with #5772
#5772 in a safe way, but
we should probably centralize this logic in one place or the other.


Reply to this email directly or view it on GitHub
#5724 (comment)
.

@efiring

efiring commented Dec 31, 2015

Copy link
Copy Markdown
Member

On 2015/12/31 9:30 AM, Thomas A Caswell wrote:

This interacts with #5772
#5772 in a safe way, but
we should probably centralize this logic in one place or the other.

If so, the logic definitely belongs in ticker, not in axis. It probably
makes sense for ticker to handle the case of _tick_space == 0.

One could go farther, and argue that axis should only supply the
estimated label size and axis length, and leave everything else to the
ticker.

@efiring

efiring commented Dec 31, 2015

Copy link
Copy Markdown
Member

On 2015/12/31 9:44 AM, Benjamin Root wrote:

just thinking out loud, would it make sense to use a logarithm for the
number of bins? I am imagining edge cases where users want really long time
series. we have had users hitting limits in the agg renderer before with
very big plots.

I don't understand; would you elaborate, please? How would a logarithm
be used?

@tacaswell

Copy link
Copy Markdown
Member

I will rebase my PR on top of this one.

@WeatherGod

WeatherGod commented Dec 31, 2015 via email

Copy link
Copy Markdown
Member

@efiring

efiring commented Dec 31, 2015

Copy link
Copy Markdown
Member

@WeatherGod, I think using a log of the axis size would add more complexity than it would be worth. This is all for trying to automatically make a plot look decent on the screen. The axis size really can't get all that large. The very large case would be something like a poster; but at that point the user is going to need to specify all sorts of things manually anyway.

@jenshnielsen

Copy link
Copy Markdown
Member

Any objections to merging this?

efiring added a commit that referenced this pull request Jan 24, 2016
Set maximum number of bins in ticking
@efiring efiring merged commit 042ad99 into matplotlib:v2.x Jan 24, 2016
@efiring

efiring commented Jan 24, 2016

Copy link
Copy Markdown
Member

This is a clear and simple improvement that needs to go in, so I merged it. I suspect that somewhere along the line the tick strategy might need to be revisited, but that needn't block this incremental improvement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants