Issue
I have already looked through a bunch of posts and solution, the consensus is usually to change the figure size by using plt.figure(figsize=(3.2, 2.4))
, which I am using for my graphs.
However, based on the x/y labels the graphs are incorrectly aligned on the output file. I am trying to insert 4 barplots in a LaTeX document:
As you see, the graphs are in correct size but very misaligned which is not very satisfying. I do not believe I can do this in latex, I would love to find a solution for python here. Is there no way I can make the output file of each graph have the same alignment? I am using seaborn for the barplots.
Solution
Okay, I have found a solution that works. By using
plt.tight_layout()
the graphs are correctly aligned on each pdf file.
Answered By - kaanginam
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.