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

getting ipmag.plot_net() to be the same size in subplots #605

Open
Swanson-Hysell opened this issue Feb 8, 2020 · 5 comments
Open

getting ipmag.plot_net() to be the same size in subplots #605

Swanson-Hysell opened this issue Feb 8, 2020 · 5 comments

Comments

@Swanson-Hysell
Copy link
Member

Is your feature request related to a problem? Please describe.
At present, when you try to embed ipmag.plot_net() within subplots they end up being different sizes. It would be nice if there are the same size. I don't know why this is happening as one would think they would be the same size.

Additional context
Here is an example (the difference is subtle, but enough to be a problem):

Screen Shot 2020-02-07 at 5 57 51 PM

@zheng-gong-pmag
Copy link

you can try to change the figure size, making the height a little smaller

@Swanson-Hysell
Copy link
Member Author

Can you give some example code that has worked to get them the same size?

@zheng-gong-pmag
Copy link

if the figure size is (10,4), then you get different sizes of subplots

Screenshot 2024-05-11 at 11 08 10 AM

if you change the figure size to (10,3), then the sizes of subplots become the same

Screenshot 2024-05-11 at 11 08 01 AM

@Swanson-Hysell
Copy link
Member Author

Interesting. That is a rather unsatisfying solution, however, as it would be nice to have an approach that makes them the same size regardless of the choice of overall dimensions.

@zheng-gong-pmag
Copy link

I guess the problem is that the plot_di_mean function was created for a single figure but if you make subplots, the code will want to fill the entire space of the figure, causing the sizing issue. I think another option is to specify the size of each subplot.

I had similar problems with Matlab. Sometimes I use the tiled layout instead of subplots to resolve the issue.

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