The linked page below shows how you put the legend above the graph.

http://matplotlib.sourceforge.net/users/plotting/legend.html#legend-location

You can put it below the axes by adjusting the bbox_to_anchor parameter.
Try something like
  bbox_to_anchor=(0., -0.1, 1., -0.1), loc=1

Make sure to adjust the suplot parameter (or axes location) to make
enough room for the legend.

-JJ



On Thu, Jun 25, 2009 at 9:22 PM, Chris Spencer<chriss...@gmail.com> wrote:
> How do you show the legend below the graph, so it doesn't overlap at
> all with the graph? The docs for the legend() "loc" parameter only
> seem to specify where *on* the graph you want it to show, which is
> driving me nuts because even using "best", it usually hides some of my
> data.
>
> I want to see *all* of my graph, as well as the legend. Is there any
> way to do this with pylab?
>
> Any help is appreciated.
>
> Chris
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>

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

Reply via email to