-
-
Notifications
You must be signed in to change notification settings - Fork 404
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
Fix for aspects of matplotlib LayoutPlot #826
Conversation
Okay this should now be ready to merge. We have decided not to enable the new behavior by default yet and wait until the v1.7 to do so. For now the new behavior can be enabled with: from holoviews.plotting.mpl import LayoutPlot
LayoutPlot.v17_layout_format = True
LayoutPlot.vspace = 0.3 |
Ok, sounds good. I'll try to enable that in all my notebooks so that it gets more testing. |
Looking forward to the improved behavior. The plan is to remove the class attribute |
Don't we have to keep |
They'll get a warning that they're setting an undefined parameter but that's it, is that an issue? |
Ah, that's not so bad. But more helpful would be for it to print a warning saying that this setting is no longer needed as it's now the default. Still, as we'd eventually want to remove that warning, maybe the undefined parameter warning is fine, then. |
You mean class attribute I presume... |
No, param will complain you're trying to set an undefined parameter. |
Ah right. Param assumes you are trying to set a parameter when really it was always just a class attribute. Just two ways of looking at it I guess... |
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
One of the major current issues with the way Layouts are handled is that the code does not take into account non-square aspects when they have not been explicitly declared (via the
aspect
plot option). This means that any plots that use 'equal' aspect can leave significant white space in a layout figure.The algorithm to resolve this problem goes as follows:
This results in significantly improved default behavior for plots with non-square aspects because unnecessary white space is removed. For now I've exposed this via a
fix_aspect
plot option but this was mostly for testing, we can consider enabling it by default, but I'd have to do some further testing first.It's worth noting that for very extreme aspects it might not get it completely right but rather than having to set a custom
fig_inches
thevspace
andhspace
will now give you much better control adjusting the spacing between plots.