Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tick labels not being factored when plotting a subsample of parameters #83

Closed
Chris-Pedersen opened this issue Oct 28, 2020 · 6 comments

Comments

@Chris-Pedersen
Copy link

Chris-Pedersen commented Oct 28, 2020

Hi!

I'm hitting an unfortunate tick label issue in that a parameter with a very small numerical value isn't having the tick labels factored out when plotting a small subsample of parameters. In the first case it works fine:

more_params

However whenever I try and only plot a subset of parameters, the ticks for the parameter A_s are no longer being factored.

less_params

I've tried playing around with the configure options, different max_ticks and font sizes, figure sizes etc, but none of this jigs the ticks into factoring. I also can't find a kwarg to pass anywhere. Do you have any suggestions? NB in the first case I'm still plotting a subsample of the parameters - there are 8 in the chain. It's only when I'm down to plotting 2 that this issue pops up.

Thanks very much!

@Samreay
Copy link
Owner

Samreay commented Oct 28, 2020

Hey Chris! How odd, this isnt intended behaviour. Are you able to share the code snippet you used (and that data as well if possible) so that I can exactly reproduce (and fix) the issue?

@Chris-Pedersen
Copy link
Author

Hi Sam, sure I'll upload a reproducible example tomorrow, thanks a lot for looking at this!

@Chris-Pedersen
Copy link
Author

I've uploaded a zip file with a small subsample of the data and a notebook that creates two plots - one with the issue and one without. Thanks!

cc_debug.zip

@Samreay
Copy link
Owner

Samreay commented Oct 30, 2020

What a weird issue! So it turns out that the current version of matplotlib should only have a single formatter per axis (matplotlib/matplotlib#15376) and the PR to support multiple axes hasnt been merged (matplotlib/matplotlib#13482). Fixing the issue by creating new x and y formatters for ever axis, and the fix should be in v0.32.0 (which should be on pip by the end of the day)

@Samreay
Copy link
Owner

Samreay commented Oct 30, 2020

v0.32.0 is now live, please let me know if this doesn't fix the issue for you :)

@Chris-Pedersen
Copy link
Author

Working for me, thanks a lot!

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

No branches or pull requests

2 participants