>>>>> "Lionel" == Lionel Roubeyrie <[EMAIL PROTECTED]> writes:

    Lionel> Hi all, I have some minor problems with legend, but I
    Lionel> don't find how to figure out: - if the figure contains
    Lionel> only one plot, the text orientation of the legend is
    Lionel> vertical. How can I change this?  - when plots are in '-'
    Lionel> style without markers, the lines are not shown in the
    Lionel> legend, I just have text.  thanks -- Lionel Roubeyrie -
    Lionel> [EMAIL PROTECTED] LIMAIR http://www.limair.asso.fr

Make sure you pass in a list of strings, and not a single string.  If
you have just a single string, it interprets it as a list of
characters.

JDH

  s = 'mylabel'
  line, = plot(something)
  legend([line], [s])


Note the comma in "line, = plot(something)" which performs tuple
unpacking of a list of lines.  plot returns a list of lines, so you
could also do

  lines = plot(something)
  legend(lines, [s])

but not

  lines = plot(something)
  legend(lines, s)

because then you have a list of lines and a sequence of characters.

JDH

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to