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

Subplots alignment #182

Open
EvgenyNerush opened this issue Mar 26, 2018 · 6 comments
Open

Subplots alignment #182

EvgenyNerush opened this issue Mar 26, 2018 · 6 comments

Comments

@EvgenyNerush
Copy link
Contributor

EvgenyNerush commented Mar 26, 2018

Is there a way to align axes size in subplots? Namely, I use the following code
gridToRenderable $ above (beside subplotA subplotB) (beside subplotC subplotD)
in order to draw this figure:
image
I would like to have the same size of vertical axes in all plots, and the same size of all horizontal axes. Is it possible to achieve?

@EvgenyNerush
Copy link
Contributor Author

P.S. Could you, please, comment on my pull request #176 . What is wrong with it (it works fine on my machine)?

@timbod7
Copy link
Owner

timbod7 commented Mar 26, 2018

Can you describe what you mean be "align axes sizes" ? Do you want axes to show the same numeric ranges, or just occupy consistent physical space on the page?

@EvgenyNerush
Copy link
Contributor Author

I meant the same size in pixels ("occupy consistent physical space on the page"). E.g., almost all z-axes in Fig. above have the same numeric ranges, but different sizes. This looks not good.

@timbod7
Copy link
Owner

timbod7 commented Mar 28, 2018

I understand - currently in your example the plot area is what remains after area has been alllocated to axes, legends and titles. If the space taken by these are inconsistent, the the different plot areas will not be the same.

A layout algorithm is required that ensures that all axes are given the same space, titles the same space, etc so the plot areas are consistently sized. Such an algorithm exists for a vertical stack of plots (see https://hackage.haskell.org/package/Chart-1.8.3/docs/Graphics-Rendering-Chart-Layout.html#t:StackedLayouts) but not currently for a grid of plots.

@Magalame
Copy link

Magalame commented Jan 3, 2019

@EvgenyNerush Hi, would you mind sharing your code to produce your graphs? I'm having trouble resizing mine and you seem to have completely mastered it

@EvgenyNerush
Copy link
Contributor Author

What code do you mean exactly? The code for the figure above is quite complicated and requires some additional libs. If you mean just some curves in four subplots with some fontsize etc., I can give an example.

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

3 participants