@header@
 
 
matplotlib.legend
index
/usr/local/lib/python2.3/site-packages/matplotlib/legend.py

Place a legend on the axes at location loc.  Labels are a
sequence of strings and loc can be a string or an integer
specifying the legend location
 
The location codes are
 
  'best'         : 0,  
  'upper right'  : 1,  (default)
  'upper left'   : 2,
  'lower left'   : 3,
  'lower right'  : 4,
  'right'        : 5,
  'center left'  : 6,
  'center right' : 7,
  'lower center' : 8,
  'upper center' : 9,
  'center'       : 10,
 
Return value is a sequence of text, line instances that make
up the legend

 
Modules
       
sys
warnings

 
Classes
       
matplotlib.artist.Artist
Legend

 
class Legend(matplotlib.artist.Artist)
    Place a legend on the axes at location loc.  Labels are a
sequence of strings and loc can be a string or an integer
specifying the legend location
 
The location codes are
 
  'best'         : 0, 
  'upper right'  : 1,  (default)
  'upper left'   : 2,
  'lower left'   : 3,
  'lower right'  : 4,
  'right'        : 5,
  'center left'  : 6,
  'center right' : 7,
  'lower center' : 8,
  'upper center' : 9,
  'center'       : 10,
 
Return value is a sequence of text, line instances that make
up the legend
 
  Methods defined here:
__init__(self, parent, handles, labels, loc, isaxes=True, numpoints=4, prop=<matplotlib.font_manager.FontProperties instance>, pad=0.20000000000000001, markerscale=0.59999999999999998, labelsep=0.0050000000000000001, handlelen=0.050000000000000003, handletextsep=0.02, axespad=0.02, shadow=False)
  parent                # the artist that contains the legend
  handles               # a list of artists (lines, patches) to add to the legend
  labels                # a list of strings to label the legend 
  loc                   # a location code
  isaxes=True           # whether this is an axes legend
  numpoints = 4         # the number of points in the legend line
  fontprop = FontProperties(size='smaller')  # the font property
  pad = 0.2             # the fractional whitespace inside the legend border
  markerscale = 0.6     # the relative size of legend markers vs. original
  shadow                # if True, draw a shadow behind legend 
 
The following dimensions are in axes coords
  labelsep = 0.005     # the vertical space between the legend entries
  handlelen = 0.05     # the length of the legend lines
  handletextsep = 0.02 # the space between the legend line and legend text
  axespad = 0.02       # the border between the axes and legend edge
draw(self, renderer)
draw_frame(self, b)
b is a boolean.  Set draw frame to b
get_frame(self)
return the Rectangle instance used to frame the legend
get_lines(self)
return a list of lines.Line2D instances in the legend
get_patches(self)
return a list of patch instances in the legend
get_texts(self)
return a list of text.Text instance in the legend
get_window_extent(self)

Data and other attributes defined here:
codes = {'best': 0, 'center': 10, 'center left': 6, 'center right': 7, 'lower center': 8, 'lower left': 3, 'lower right': 4, 'right': 5, 'upper center': 9, 'upper left': 2, ...}

Methods inherited from matplotlib.artist.Artist:
add_callback(self, func)
get_alpha(self)
Return the alpha value used for blending - not supported on all
backends
get_clip_box(self)
Return artist clipbox
get_clip_on(self)
Return whether artist uses clipping
get_figure(self)
return the figure instance
get_label(self)
get_transform(self)
return the Transformation instance used by this artist
get_visible(self)
return the artist's visiblity
get_zorder(self)
is_figure_set(self)
is_transform_set(self)
Artist has transform explicity let
pchanged(self)
fire event when property changed
remove_callback(self, oid)
set_alpha(self, alpha)
Set the alpha value used for blending - not supported on
all backends
 
ACCEPTS: float
set_clip_box(self, clipbox)
Set the artist's clip Bbox
 
ACCEPTS: a matplotlib.transform.Bbox instance
set_clip_on(self, b)
Set  whether artist uses clipping
 
ACCEPTS: [True | False]
set_figure(self, fig)
Set the figure instance the artist belong to
 
ACCEPTS: a matplotlib.figure.Figure instance
set_label(self, s)
Set the line label to s for auto legend
 
ACCEPTS: any string
set_lod(self, on)
Set Level of Detail on or off.  If on, the artists may examine
things like the pixel width of the axes and draw a subset of
their contents accordingly
 
ACCEPTS: [True | False]
set_transform(self, t)
set the Transformation instance used by this artist
 
ACCEPTS: a matplotlib.transform transformation instance
set_visible(self, b)
set the artist's visiblity
 
ACCEPTS: [True | False]
set_zorder(self, level)
Set the zorder for the artist
 
ACCEPTS: any number
update(self, props)
update_from(self, other)
copy properties from other to self

Data and other attributes inherited from matplotlib.artist.Artist:
aname = 'Artist'
zorder = 0

 
Functions
       
Bbox(...)
Bbox(ll, ur)
Point(...)
Point(x, y)
Value(...)
Value(x)
array(...)
array(sequence, typecode=None, copy=1, savespace=0) will return a new array formed from the given (potentially nested) sequence with type given by typecode.  If no typecode is given, then the type will be determined as the minimum type required to hold the objects in sequence.  If copy is zero and sequence is already an array, a reference will be returned.  If savespace is nonzero, the new array will maintain its precision in operations.

 
Data
        Float = 'd'
division = _Feature((2, 2, 0, 'alpha', 2), (3, 0, 0, 'alpha', 0), 8192)
verbose = <matplotlib.Verbose instance>
@footer@