Re: [Matplotlib-users] question about tight_layout()

2011-10-16 Thread Jae-Joon Lee
On Sun, Oct 16, 2011 at 1:55 PM, C M cmpyt...@gmail.com wrote: However, I can't get it to work correct with Figure.  I'm either getting that same error or failure to adjust the Figure's size to accommodate the axes' labels.  I attach a minimal runnable sample that demonstrates these problems

Re: [Matplotlib-users] question about tight_layout()

2011-10-16 Thread C M
In your example code, do you see the error raised only when you include the tight_layout call? Yes. To see this (at least on my platform), you take the example code and try two things: 1) Comment IN this line: self.panel.Layout(). Run it and you'll get the error. 3) Now comment OUT the

Re: [Matplotlib-users] question about tight_layout()

2011-10-16 Thread Jae-Joon Lee
On Mon, Oct 17, 2011 at 1:03 AM, C M cmpyt...@gmail.com wrote: - Error if I call self.panel.Layout() before I call tight_layout(). In my system, I don't see any error whether ` self.panel.Layout() is in or not. - If I don't do this, no error, but it still isn't doing a proper tight layout.

Re: [Matplotlib-users] question about tight_layout()

2011-10-16 Thread C M
So, it seems that the issue is platform-dependent. OK. As for the error message, it seems that the subplot_params values (left, right, top, bottom, etc) calculated by the tight_layout routine is somehow corrupted. Why this happens is hard to track down unless I can reproduce the error. And

Re: [Matplotlib-users] question about tight_layout()

2011-10-15 Thread Jae-Joon Lee
Figure.tight_layout() is a correct way. Do you see that error only when you use Figure.tight_plot (and not when you use plt.tight_layout)? What happen you try the script below. import matplotlib.pyplot as plt fig = plt.figure(1)ax = fig.add_subplot(111)fig.tight_layout() Regards, -JJ On Sat,

Re: [Matplotlib-users] question about tight_layout()

2011-10-15 Thread C M
On Sat, Oct 15, 2011 at 10:15 AM, Jae-Joon Lee lee.j.j...@gmail.com wrote: Figure.tight_layout() is a correct way. Do you see that error only when you use Figure.tight_plot (and not when you use plt.tight_layout)? Yes. What happen you try the script below. import matplotlib.pyplot as

[Matplotlib-users] question about tight_layout()

2011-10-14 Thread C M
Just trying out the latest mpl 1.1.0 and the tight_layout() method. I saw the guide written about it, but am a unsure how to use this when using the OO approach to using Matplotlib. When using pyplot, the method is: plt.tight_layout(). When using the OO form of mpl, is it: