Re: [Matplotlib-users] Dynamic adjustment of axis position and size in figure

2012-03-03 Thread Jae-Joon Lee
tight_layout only works for instances of Subplots. However, ax2, which is created by calling twinx, is an instance of Axes, and is not accounted by the tight_layout command.It may be possible to improve the situation, I doubt it would be easy as the association between ax1 and ax2 is not very expli

Re: [Matplotlib-users] Dynamic adjustment of axis position and size in figure

2011-12-07 Thread Jérôme
Wed, 7 Dec 2011 20:29:22 +0100 Jérôme a écrit: > Is there a way to automatically resize the axis and nicely center the whole > set {axes + ticklabels + labels} in the figure ? > > One could use add_axes and play with the coordinates until he gets something > nice, but it gets complicated to have

Re: [Matplotlib-users] Dynamic adjustment of axis position and size in figure

2011-12-07 Thread Jérôme
Hi again. Wed, 7 Dec 2011 20:29:22 +0100 Jérôme a écrit: > Is there a way to automatically resize the axis and nicely center the whole > set {axes + ticklabels + labels} in the figure ? [...] > Or did I miss something ? It seems I missed figure.tight_layout(). Sorry about that... -- Jérôme

[Matplotlib-users] Dynamic adjustment of axis position and size in figure

2011-12-07 Thread Jérôme
Hi all. The position of an axes is fixed at creation, regardless of the what goes outside the plot area. If the numbers on the y-axis are big enough (say, 7 digits) and a label is added, the label gets out of the figure. Example : -