Many thanks!

carlos

On Thu, Apr 22, 2010 at 18:54, Gökhan Sever <gokhanse...@gmail.com> wrote:
>
>
> On Thu, Apr 22, 2010 at 4:44 PM, Carlos Grohmann <carlos.grohm...@gmail.com>
> wrote:
>>
>> Hi all,
>>
>> I'm getting this weird behavior of legend. I always get two symbols in
>> front of the labels, instead of one.
>> Did anyone experienced this before?
>>
>> I'm working with MPL in a WxPython app.
>>
>> code snippet:
>>
>>
>> [code]
>>            for i in range(len(self.idxPlan)):
>>                x = self.PeigenList[i][14] + (self.PeigenList[i][15] / 2)
>>                y = self.PeigenList[i][15] * sqrt3_2
>>                axes.plot(x,y, self.PProps[i][3], c=self.PProps[i][2],
>> ms=self.PProps[i][4],label=self.Pname[i])
>>
>>            axes.legend(bbox_to_anchor=(0.85, 0.75), loc=2,
>> prop=FontProperties(size='small'))
>>
>>            axes.set_xlim(-0.1,1.2)
>>            axes.set_ylim(-0.1,1.2)
>>            self.dataCanvas.draw()
>>
>> [\code]
>>
>>
>> tks
>> --
>> Prof. Carlos Henrique Grohmann - Geologist D.Sc.
>> Institute of Geosciences - Univ. of São Paulo, Brazil
>> http://www.igc.usp.br/pessoais/guano
>> Linux User #89721
>> ________________
>> Can’t stop the signal.
>
> Hi,
>
> Try using numpoints keyword:
>
> plt.legend(numpoints=1)
>
>
> --
> Gökhan
>



-- 
Prof. Carlos Henrique Grohmann - Geologist D.Sc.
Institute of Geosciences - Univ. of São Paulo, Brazil
http://www.igc.usp.br/pessoais/guano
Linux User #89721
________________
Can’t stop the signal.

------------------------------------------------------------------------------
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to