[Matplotlib-users] Resize error with Qt4 backend

2009-07-01 Thread Brian Zambrano
Hi all, I'm having a problem with resizing a FigureCanvas using the Qt4 backend when the FigureCanvas is used alongside some dock widgets. What happens is that the figure never grows beyond the original size set when the window or other dock widgets are expanded. It's probably easier to look at

Re: [Matplotlib-users] Zooming plot and transforms...

2009-07-01 Thread Fabrice Silva
Le mercredi 01 juillet 2009 à 10:13 +0200, Sandro Tosi a écrit : > On Tue, Jun 30, 2009 at 14:12, Fabrice Silva wrote: > > Le lundi 29 juin 2009 à 16:11 -0400, Jae-Joon Lee a écrit : > >> In the svn version of matplotlib, there are some helper classes to > >> ease this job a bit. > > Thanks for you

[Matplotlib-users] how to plot in discontinued Y-axis

2009-07-01 Thread Forrest Sheng Bao
Hi, I am thinking about a plotting problem with the data set like this: [3,2,4,100,5] If I plot this list, then 100 will be very high and 3, 2, 4 and 5 will be almost near 0. So, can I use a discontinued Y-axis, which has two ranges, from 0 to 10 and from 90 to 110. Of course, there needs a tear

Re: [Matplotlib-users] Pre-defined binning with hexbin ... impossible?

2009-07-01 Thread Jeff Whitaker
Alexandar Hansen wrote: > Hello, > > I've been struggling with this for a while now and have effectively > two issues. One, how can I define the range over which hexbin ... > bins? And two, how do I change the background color of a plot? Alexandar: To change the background color to the lowest v

[Matplotlib-users] matplotlib-0.98.5.3.win32-py2.6.exe

2009-07-01 Thread Stephen George
Hi, I just downloaded matplotlib-0.98.5.3.win32-py2.6.exe from sourceforge. I have an existing Application that works fine with python : 2.5.4 final 0 pyGTK: 2.12.1 GTK+ : 2.14.7 numpy: 1.2.1 matplotlib : 0.98.5.2 Now I am trying the same App on python version

Re: [Matplotlib-users] Resize error with Qt4 backend

2009-07-01 Thread Brian Zambrano
As usual, I ended up figuring this out after I sent this question. The trick was adding the central widget (FigureCanvas) to a QLayout, and just ignoring the resizeEvent. So, I just did: vbox = QVBoxLayout() vbox.addWidget(self.canvas) self.setLayout(vbox) in the custom QWidget which holds the

[Matplotlib-users] memory leak with PyQt4 plus savefig or print_figure

2009-07-01 Thread Ralf Gommers
Hi, I am working on a PyQt4 application with some embedded MPL figures, and am also trying to save some figures as png's without displaying them. I am observing huge memory increases (10s or 100s of Mb) the moment I try to save a png. I reproduced the issue by combining two mpl examples, http://ma

Re: [Matplotlib-users] ImportError: No module named mplot3d

2009-07-01 Thread Gökhan SEVER
On Wed, Jul 1, 2009 at 3:25 PM, David Paulsen wrote: > Script passed the previous error point, and a different error string this > time: > >  File "3D_line_plot_ex.py", line 32, in >    ax.add_collection3d(poly, zs=zs, zdir='y') > >  File > "/Library/Frameworks/Python.framework/Versions/4.2.30201/

Re: [Matplotlib-users] to much points

2009-07-01 Thread Michael Droettboom
This should now be fixed on the maintenance branch and trunk. A Numpy array allocation was not being NULL-checked in _path.cpp:affine_transform. I know a MemoryError doesn't help the user much more than a segfault, but it always makes me feel better to get a real Python exception rather than

Re: [Matplotlib-users] to much points

2009-07-01 Thread Jae-Joon Lee
I tracked this down do line 962 of the _path.cpp. double* vertex_out = (double*)PyArray_DATA(result); My guess is that PyArray_SimpleNew at line 957 returns NULL for a memory error instead of raising an exception, which makes result=NULL and causes a segfault at line 962. Since I'm n

Re: [Matplotlib-users] to much points

2009-07-01 Thread Jae-Joon Lee
On Wed, Jul 1, 2009 at 2:34 PM, Michael Droettboom wrote: > I agree with Jae-Joon here -- try to reduce the number of points before > passing it to matplotlib. > > However, I'm a little concerned about the segfault -- I'd rather matplotlib > give a MemoryError exception if that's in fact what is ha

Re: [Matplotlib-users] to much points

2009-07-01 Thread Michael Droettboom
I agree with Jae-Joon here -- try to reduce the number of points before passing it to matplotlib. However, I'm a little concerned about the segfault -- I'd rather matplotlib give a MemoryError exception if that's in fact what is happening. Jae-Joon -- can you share your test that causes the s

Re: [Matplotlib-users] to much points

2009-07-01 Thread Jae-Joon Lee
A snippet of code does not help much. Please try to post a small concise standalone example that we can run and test. A general advise is to try to reduce the number of plot call, i.e., plot as may points as possible with a single plot call. However, 50million points seems to be awful a lot. 6 i

Re: [Matplotlib-users] log scale the Y axis of a stem plot

2009-07-01 Thread Jae-Joon Lee
yscale("log") http://matplotlib.sourceforge.net/api/pyplot_api.html#matplotlib.pyplot.yscale However the bars in the stem plot will be gone (because of the log 0). It seems that there is no option for controling the baseline location in the stem command. However, the code for stem command is qui

Re: [Matplotlib-users] ImportError: No module named mplot3d

2009-07-01 Thread Gökhan SEVER
On Wed, Jul 1, 2009 at 9:55 AM, David Paulsen wrote: > Dear List, > > I tried running examples of 3D plots given from the matplotlib webpage, but > encountered the following error: > > > from mpl_toolkits.mplot3d import Axes3D > ImportError: No module named mplot3d > > I am using the enthought

Re: [Matplotlib-users] Remove Patch Rectangle Around Plot

2009-07-01 Thread Mark Larsen
> I think what you want is > > ax = fig.add_subplot(111,frameon=False) > > JLS D'oh, I knew it had to be easy. Thanks JLS. -- ___ Matplotlib-users mailing list Matplotlib-users

Re: [Matplotlib-users] ImportError: No module named mplot3d

2009-07-01 Thread Sandro Tosi
On Wed, Jul 1, 2009 at 16:55, David Paulsen wrote: > from mpl_toolkits.mplot3d import Axes3D > ImportError: No module named mplot3d > > I am using the enthought package with matplotlib version 0.98.5.2 > > Any help on how to recover mplot 3d would be appreciated. mplot3d still lives only under

Re: [Matplotlib-users] Remove Patch Rectangle Around Plot

2009-07-01 Thread João Luís Silva
Mark Larsen wrote: > Hopefully a really simple question. How do I remove the "box" (the > black rectangle) around the plot. > > I tried > > ax = fig.add_subplot(111) > ax.patch.set_visible(False) > > but this makes the entire patch invisible. > > Thanks, > > Mark > >

[Matplotlib-users] ImportError: No module named mplot3d

2009-07-01 Thread David Paulsen
Dear List, I tried running examples of 3D plots given from the matplotlib webpage, but encountered the following error: from mpl_toolkits.mplot3d import Axes3D ImportError: No module named mplot3d I am using the enthought package with matplotlib version 0.98.5.2 Any help on how to recover

[Matplotlib-users] Remove Patch Rectangle Around Plot

2009-07-01 Thread Mark Larsen
Hopefully a really simple question. How do I remove the "box" (the black rectangle) around the plot. I tried ax = fig.add_subplot(111) ax.patch.set_visible(False) but this makes the entire patch invisible. Thanks, Mark -

[Matplotlib-users] log scale the Y axis of a stem plot

2009-07-01 Thread Forrest Sheng Bao
Him I had a stem plot. Now I want to make the Y axis of log scale. But I do not want to use semilogy since I prefer the bars in stem plot. Do you know how to only scale the Y axis? Cheers, Forrest Forrest Sheng Bao, BSEE, Graduate Student Dept. of Computer Science/Electrical Engineering Texas Te

[Matplotlib-users] Highlighting the axes of coordinates

2009-07-01 Thread Torsten Bronger
Hallöchen! I have a grid in my plot, but additionally I'd like to highlight the "zero" axes, where x=0 or y=0, e.g. by showing them in red, or with thicker lines. How is this possible? Tschö, Torsten. -- Torsten Bronger, aquisgrana, europa vetus Jabber ID: torsten.bron...@ja

Re: [Matplotlib-users] Zooming plot and transforms...

2009-07-01 Thread Sandro Tosi
On Tue, Jun 30, 2009 at 14:12, Fabrice Silva wrote: > Le lundi 29 juin 2009 à 16:11 -0400, Jae-Joon Lee a écrit : >> In the svn version of matplotlib, there are some helper classes to >> ease this job a bit. > Thanks for your pointer. Sadly the mpl.toolkits.axes_grid is not shipped > by debian pack

Re: [Matplotlib-users] Tutorial topics for SciPy'09 Conference

2009-07-01 Thread Fernando Perez
Hi, On Mon, Jun 1, 2009 at 10:20 PM, Fernando Perez wrote: > The time for the Scipy'09 conference is rapidly approaching, and we > would like to both announce the plan for tutorials and solicit > feedback from everyone on topics of interest. rather than rehash much here, where it's not easy to pa