This has now been fixed in SVN r5975 and r5976.  This should make it 
into the next official release, or if you can try applying the patches 
from those SVN revisions.  The fixes are a bit scattered, so YMMV.

Cheers,
Mike

Ben Axelrod wrote:
> Thanks,
>
> I think it is great that the color can be specified as either 3 or 4 columns. 
>  It would be nice if the bar plot color arguments also had this flexibility.  
> They currently fail when the color has 4 columns.
>
> Will this bug fix need to wait until the next official release?  (I am 
> constrained to using the official releases and not the svn code).
>
> Thanks,
> -Ben
>
> -----Original Message-----
> From: Michael Droettboom [mailto:[EMAIL PROTECTED]
> Sent: Monday, August 04, 2008 10:17 AM
> To: Ben Axelrod
> Cc: matplotlib-users@lists.sourceforge.net
> Subject: Re: [Matplotlib-users] 0.98.3 scatter plot color bug?
>
> Looks like a bug -- it should accept either 3 or 4 columns. I'll have a
> chance to look at this further this afternoon.
>
> Cheers,
> Mike
>
> Ben Axelrod wrote:
>   
>> I get an error when I use the scatter plot and set the 'c' value to a
>> list of 3-tuples. The error goes away if I use 4-tuples instead. Are
>> colors with only 3 values not supported anymore?
>>
>> ...
>>
>> File "C:\Python24\Lib\site-packages\matplotlib\axes.py", line 4807, in
>> scatter
>>
>> colors = mcolors.colorConverter.to_rgba_array(c, alpha)
>>
>> File "C:\Python24\Lib\site-packages\matplotlib\colors.py", line 343,
>> in to_rgba_array
>>
>> c[i] = self.to_rgba(cc, alpha) # change in place
>>
>> ValueError: shape mismatch: objects cannot be broadcast to a single shape
>>
>> ------------------------------------------------------------------------
>>
>> -------------------------------------------------------------------------
>> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
>> Build the coolest Linux based applications with Moblin SDK & win great prizes
>> Grand prize is a trip for two to an Open Source event anywhere in the world
>> http://moblin-contest.org/redirect.php?banner_id=100&url=/
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Matplotlib-users mailing list
>> Matplotlib-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>>
>>     
>
> --
> Michael Droettboom
> Science Software Branch
> Operations and Engineering Division
> Space Telescope Science Institute
> Operated by AURA for NASA
>
>   

-- 
Michael Droettboom
Science Software Branch
Operations and Engineering Division
Space Telescope Science Institute
Operated by AURA for NASA


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to