|
From: Charleux L. <lud...@gm...> - 2012-10-03 18:11:11
|
Thanks for your multiple answers. I'll try the same manipulation with the 1.2 version as soon as possible. Concerning the debate between the use of None and numpy.nan, I tryed both methods before posting and they both lead to the same bug on my version. I'm using the None/numpy.nan trick to plot finite element 2D meshes (Matplotlib allows very neat vectorial plots) and I often adjust xlim/ylim to magnify interesting zones and so this bug is everywhere. I'm not totally sure but I think the bug was not present in the 1.0.x versions I tested before. Regards. Ludovic Charleux 2012/10/3 Benjamin Root <ben...@ou...> > > > On Wed, Oct 3, 2012 at 1:02 PM, Phil Elson <pel...@gm...> wrote: > >> I don't get this on matplotlib/master (and therefore probably not on >> 1.2rc2). >> >> I'm pretty sure masked array line plotting was fixed at some point this >> release cycle (I cannot find the appropriate github issue to link to), so I >> suggest this is a known bug with 1.1.1 and fixed in 1.2. Just to be clear, >> I am using the TkAgg backend, and there is a remote possiblity that this >> bug is backend dependent. Is there any chance you could test this with the >> latest release candidate? >> >> Many Thanks, >> >> > This issue may be dependent upon which version of Numpy one is using. As > Eric pointed out, one should be getting an object array if you have a None > in the list. On top of that, I wouldn't be surprised if the different > backends handled this object array differently. > > As far as I am concerned, using None in the list is the bug and is not > only unsupported, but should be actively discouraged. Use NaNs or masked > arrays instead. > > (and to ward off the inevitable question, I would advise against > explicitly checking for object arrays because there are times when it is > correct to have such arrays, i.e., python decimal or datetime objects). > > Cheers! > Ben Root > > |