/opt/alt/python27/lib64/python2.7/site-packages/matplotlib
NameSizeModeActions
backends/-0755rm
delaunay/-0755rm
mpl-data/-0755rm
numerix/-0755rm
projections/-0755rm
sphinxext/-0755rm
afm.py150890644editdlrm
afm.pyc173880644editdlrm
afm.pyo173880644editdlrm
artist.py356230644editdlrm
artist.pyc414310644editdlrm
artist.pyo414310644editdlrm
axes.py2800890644editdlrm
axes.pyc2525680644editdlrm
axes.pyo2514560644editdlrm
axis.py573540644editdlrm
axis.pyc608580644editdlrm
axis.pyo605510644editdlrm
backend_bases.py723180644editdlrm
backend_bases.pyc799690644editdlrm
backend_bases.pyo798790644editdlrm
bezier.py149170644editdlrm
bezier.pyc138120644editdlrm
bezier.pyo138120644editdlrm
blocking_input.py136900644editdlrm
blocking_input.pyc147620644editdlrm
blocking_input.pyo144440644editdlrm
cbook.py427560644editdlrm
cbook.pyc586920644editdlrm
cbook.pyo584660644editdlrm
cm.py80980644editdlrm
cm.pyc100320644editdlrm
cm.pyo100320644editdlrm
collections.py407840644editdlrm
collections.pyc451110644editdlrm
collections.pyo451110644editdlrm
colorbar.py274560644editdlrm
colorbar.pyc258350644editdlrm
colorbar.pyo258350644editdlrm
colors.py391100644editdlrm
colors.pyc406900644editdlrm
colors.pyo406900644editdlrm
contour.py428950644editdlrm
contour.pyc364630644editdlrm
contour.pyo363010644editdlrm
dates.py360070755editdlrm
dates.pyc411350644editdlrm
dates.pyo410710644editdlrm
dviread.py320330644editdlrm
dviread.pyc354880644editdlrm
dviread.pyo353450644editdlrm
figure.py412640644editdlrm
figure.pyc437060644editdlrm
figure.pyo435750644editdlrm
finance.py205820644editdlrm
finance.pyc186750644editdlrm
finance.pyo185150644editdlrm
fontconfig_pattern.py64290644editdlrm
fontconfig_pattern.pyc67100644editdlrm
fontconfig_pattern.pyo67100644editdlrm
font_manager.py426530644editdlrm
font_manager.pyc412750644editdlrm
font_manager.pyo412750644editdlrm
ft2font.so3061680755editdlrm
hatch.py65640644editdlrm
hatch.pyc94840644editdlrm
hatch.pyo94840644editdlrm
image.py315400644editdlrm
image.pyc337830644editdlrm
image.pyo337370644editdlrm
legend.py323020644editdlrm
legend.pyc238760644editdlrm
legend.pyo237030644editdlrm
lines.py546850644editdlrm
lines.pyc579910644editdlrm
lines.pyo578860644editdlrm
mathtext.py1020090644editdlrm
mathtext.pyc1060700644editdlrm
mathtext.pyo1056820644editdlrm
mlab.py942940644editdlrm
mlab.pyc1019150644editdlrm
mlab.pyo1017350644editdlrm
mpl.py7850644editdlrm
mpl.pyc11890644editdlrm
mpl.pyo11890644editdlrm
nxutils.so97040755editdlrm
offsetbox.py298070644editdlrm
offsetbox.pyc348250644editdlrm
offsetbox.pyo347700644editdlrm
patches.py1284850644editdlrm
patches.pyc1337360644editdlrm
patches.pyo1335980644editdlrm
path.py217650644editdlrm
path.pyc214990644editdlrm
path.pyo212790644editdlrm
pylab.py109810644editdlrm
pylab.pyc124380644editdlrm
pylab.pyo124380644editdlrm
pyparsing.py1439240644editdlrm
pyparsing.pyc1511830644editdlrm
pyparsing.pyo1511830644editdlrm
pyplot.py824680644editdlrm
pyplot.pyc819820644editdlrm
pyplot.pyo819820644editdlrm
quiver.py375400644editdlrm
quiver.pyc341520644editdlrm
quiver.pyo341520644editdlrm
rcsetup.py234340644editdlrm
rcsetup.pyc215220644editdlrm
rcsetup.pyo213520644editdlrm
scale.py142330644editdlrm
scale.pyc202540644editdlrm
scale.pyo202540644editdlrm
spines.py126840644editdlrm
spines.pyc118830644editdlrm
spines.pyo114560644editdlrm
table.py168280644editdlrm
table.pyc173730644editdlrm
table.pyo172220644editdlrm
texmanager.py224640644editdlrm
texmanager.pyc202090644editdlrm
texmanager.pyo202090644editdlrm
text.py598220644editdlrm
text.pyc606960644editdlrm
text.pyo606960644editdlrm
ticker.py404280644editdlrm
ticker.pyc521640644editdlrm
ticker.pyo520280644editdlrm
tight_bbox.py36550644editdlrm
tight_bbox.pyc41570644editdlrm
tight_bbox.pyo41570644editdlrm
transforms.py753870644editdlrm
transforms.pyc924320644editdlrm
transforms.pyo915230644editdlrm
ttconv.so654880755editdlrm
type1font.py115370644editdlrm
type1font.pyc114900644editdlrm
type1font.pyo114900644editdlrm
units.py49760644editdlrm
units.pyc59180644editdlrm
units.pyo59180644editdlrm
widgets.py408330644editdlrm
widgets.pyc436080644editdlrm
widgets.pyo434220644editdlrm
windowing.py4540644editdlrm
windowing.pyc13610644editdlrm
windowing.pyo13610644editdlrm
_cm.py3704140644editdlrm
_cm.pyc1030550644editdlrm
_cm.pyo1030550644editdlrm
_cntr.so209600755editdlrm
_delaunay.so611840755editdlrm
_image.so2828560755editdlrm
_mathtext_data.py579900644editdlrm
_mathtext_data.pyc638000644editdlrm
_mathtext_data.pyo638000644editdlrm
_path.so2803120755editdlrm
_png.so1565040755editdlrm
_pylab_helpers.py27150644editdlrm
_pylab_helpers.pyc38380644editdlrm
_pylab_helpers.pyo38380644editdlrm
__init__.py289720644editdlrm
__init__.pyc294350644editdlrm
__init__.pyo293810644editdlrm
Edit: /opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyo (43575B)
(Jc@sdZddkZddkZddklZlZddklZlZl Z ddk l Z l Z l Z lZlZddkZddkZddklZddklZddklZdd klZlZdd klZdd klZl Z l!Z!l"Z"dd k#l$Z$l%Z%l&Z&dd k'l(Z(l)Z)ddk*i Z dfdYZ+defdYZ,dZ-ei.e,ei/d= rightsbottom cannot be >= topN( tgetattrtNonet _update_thisRRR t ValueErrorRR!(RRRR R!R"R#R+((R%R&RR)R*R(R'sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRCs(! cCs\|djo;t||d}|djod|}t|}qHnt|||dS(Nsfigure.subplot.(R-R,R tsetattr(Rtstvaltkey((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyR.ms    N(t__name__t __module__t__doc__R-R$RR.(((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyR$s   )tFigurec BseZdZdZd>d>d>d>ded>dZdZdZe eeZ dddd Z d Z d Z d Zd ZdZd>dZdddd>d>d>d>d>dZdZdZdZdZdZdZdZdZdZdZdZdZdZdZ d Z!d!Z"d"Z#d#Z$e%e$ihd$i&e'd%6e(i)d&d&6e$_d'Z*e%e*ihd$i&e'd%6e(i)d&d&6e*_d(Z+d)Z,e-d*Z.d+Z/d,Z0d-Z1d.Z2e%e2ie(i)e2_d/Z3d0Z4e%e4ie(i)e4_d1Z5d2Z6d3Z7d>d>d4Z8d5e9i:e8_d6Z;d7ded7d8d9d:Z<d;d<Z=d=Z>RS(?s The Figure instance supports callbacks through a *callbacks* attribute which is a :class:`matplotlib.cbook.CallbackRegistry` instance. The events you can connect to are 'dpi_changed', and the callback will be called with ``func(fig)`` where fig is the :class:`Figure` instance. The figure patch is drawn by a the attribute *patch* a :class:`matplotlib.patches.Rectangle` instance *suppressComposite* for multiple figure images, the figure will make composite images depending on the renderer option_image_nocomposite function. If suppressComposite is True|False, this will override the renderer cCsdt|iiS(Ns Figure(%gx%g)(ttupletbboxtsize(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt__str__sg?c Csti|tid|_|djotd}n|djotd}n|djotd}n|djotd}nt|_||_ t i dd||_ t |i |i|_||_t|i|_tdddd d d d |d |d ||_|_|i|itd|_d|_|djo t}n||_t|_g|_|id|_dS(s& *figsize* w,h tuple in inches *dpi* dots per inch *facecolor* the figure patch facecolor; defaults to rc ``figure.facecolor`` *edgecolor* the figure patch edge color; defaults to rc ``figure.edgecolor`` *linewidth* the figure patch edge linewidth; the default linewidth of the frame *frameon* if False, suppress drawing the figure frame *subplotpars* a :class:`SubplotParams` instance, defaults to rc t dpi_changedsfigure.figsizes figure.dpisfigure.facecolorsfigure.edgecoloritxytwidthitheightt facecolort edgecolort linewidths axes.holdN(R<(ii(RR$tcbooktCallbackRegistryt callbacksR-R Rtdpi_scale_transtdpiRt from_boundst bbox_inchesRR9tframeonRt transFigureR tpatcht figurePatcht_set_artist_propst_holdtcanvasRt subplotparsRt_axstacktaxestclft_cachedRenderer(RtfigsizeRGR@RARBRJRQ((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyR$s<                 cCs|iS(N(t_dpi(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt_get_dpiscCs9||_|iii|||iid|dS(NR<(RWRFtcleartscaleREtprocess(RRG((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt_set_dpis g?iR cCs5tig}|iD]}|t|dq~}t|idjo5x|iD] }|i||i|qYWn|ox|iD]y}|i o5xc|iD] }|i||i|qWqx!|iD]}|i t qW|i dqWn|o|i d|ndS(s] Date ticklabels often overlap, so it is useful to rotate them and right align them. Also, a common use case is a number of subplots with shared xaxes where the x-axis is date data. The ticklabels are often long, and it helps to rotate them on the bottom subplot and turn them off on other subplots, as well as turn off xlabels. *bottom* the bottom of the subplots for :meth:`subplots_adjust` *rotation* the rotation of the xtick labels *ha* the horizontal alignment of the xticklabels t is_last_rowitRN(tnptalltrueRSthasattrtlentget_xticklabelstset_hat set_rotationtget_axesR]t set_visibletFalset set_xlabeltsubplots_adjust(RRtrotationthat_[1]taxt allsubplotstlabel((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt autofmt_xdates(6       cCs|ig}|i|i|i|i|i|i|i|i|i|i|i|i|i|i|S(s-get a list of artists contained in the figure( RLtextendtartistsRStlinestpatchesttextstimagestlegends(Rtchildren((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt get_childrens cCsFt|io|i||S|ii|i|i}|hfS(s_ Test whether the mouse event occurred on the figure. Returns True,{} (tcallablet _containsR9tcontainstxty(Rt mouseeventtinside((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyR}scOs|iS(s=get the figure bounding box in display space; kwargs are void(R9(Rtargstkwargs((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytget_window_extentscKs|idd}|idd}d|jod|jod|d 0-1 vmin|vmax are used to scale a luminance image to 0-1. If either is None, the min and max of the luminance values will be used. Note if you pass a norm instance, the settings for *vmin* and *vmax* will be ignored. alpha the alpha blending value, default is 1.0 origin [ 'upper' | 'lower' ] Indicates where the [0,0] index of the array is in the upper left or lower left corner of the axes. Defaults to the rc image.origin value ========= ========================================================== figimage complements the axes image (:meth:`~matplotlib.axes.Axes.imshow`) which will be resampled to fit the current axes. If you want a resampled image to fill the entire figure, you can define an :class:`~matplotlib.axes.Axes` with size [0,1,0,1]. An :class:`matplotlib.image.FigureImage` instance is returned. .. plot:: mpl_examples/pylab_examples/figimage_demo.py N( RORTR t set_arrayt set_alphaR-tset_climRwtappend( RtXtxotyotalphatnormtcmaptvmintvmaxtorigintim((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytfigimagePs<    cOs0ddk}|idt|i||dS(NisUse set_size_inches instead!(twarningstwarntDeprecationWarningtset_size_inches(RRRR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytset_figsize_inchess c Os|idt}t|djo|d\}}n |\}}|i}||f|i_|oc|i}||}||}t|idd} | dj o | i t |t |qndS(s set_size_inches(w,h, forward=False) Set the figure size in inches Usage:: fig.set_size_inches(w,h) # OR fig.set_size_inches((w,h) ) optional kwarg *forward=True* will cause the canvas size to be automatically updated; eg you can resize the figure window from the shell WARNING: forward=True is broken on all backends except GTK* and WX* ACCEPTS: a w,h tuple with w,h in inches tforwardiitmanagerN( tgetRhRbRGRItp1R,RPR-tresizetint( RRRRtwthtdpivaltcanvaswtcanvashR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRs      cCs |iiS(N(RIR(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytget_size_inchesscCs |iiS(s*Get the edge color of the Figure rectangle(RLt get_edgecolor(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRscCs |iiS(s*Get the face color of the Figure rectangle(RLt get_facecolor(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRscCs |iiS(sReturn the figwidth as a float(RIR>(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt get_figwidthscCs |iiS(sReturn the figheight as a float(RIR?(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt get_figheightscCs|iS(sReturn the dpi as a float(RG(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytget_dpiscCs|iS(s"get the boolean indicating frameon(RJ(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt get_frameonscCs|ii|dS(sv Set the edge color of the Figure rectangle ACCEPTS: any matplotlib color - see help(colors) N(RLt set_edgecolor(Rtcolor((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRscCs|ii|dS(sv Set the face color of the Figure rectangle ACCEPTS: any matplotlib color - see help(colors) N(RLt set_facecolor(RR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRscCs ||_dS(sM Set the dots-per-inch of the figure ACCEPTS: float N(RG(RR2((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytset_dpiscCs||i_dS(sO Set the width of the figure in inches ACCEPTS: float N(RItx1(RR2((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt set_figwidthscCs||i_dS(sP Set the height of the figure in inches ACCEPTS: float N(RIty1(RR2((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt set_figheightscCs ||_dS(so Set whether the figure frame (background) is displayed or invisible ACCEPTS: boolean N(RJ(RR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt set_frameonscCs|ii||ii|g}x8|iiD]'\}}||jo|i|=q6q6Wx|iD]}||qkWdS(s4remove a from the figure and update the current axesN(RStremoveRRt_seentitemst _axobservers(RtatkeysR3tthisaxtfunc((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytdelaxes s   cOs4d}d}||||if}|S(s*make a hashable key out of args and kwargscSsWg}xD|D]<\}}t|ot|}n|i||fq Wt|S(N(RR8R(Rtrettktv((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytfixitemss  cSsKg}x8|D]0}t|ot|}n|i|q Wt|S(N(RR8R(RRR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytfixlist#s (R(RRRRRR3((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt _make_keys c Os9|i||}||ijo|i|}|i||St|pdSt|dto|d}n|d}|idt}|idd}|o<|dj o%|djot dd|nd}nt ||||}|i i ||i i||i|||i|<|S(sK Add an a axes with axes rect [*left*, *bottom*, *width*, *height*] where all quantities are in fractions of figure width and height. kwargs are legal :class:`~matplotlib.axes.Axes` kwargs plus *projection* which sets the projection type of the axes. (For backward compatibility, ``polar=True`` may also be provided, which is equivalent to ``projection='polar'``). Valid values for *projection* are: %(list)s. Some of these projections support additional kwargs, which may be provided to :meth:`add_axes`:: rect = l,b,w,h fig.add_axes(rect) fig.add_axes(rect, frameon=False, axisbg='g') fig.add_axes(rect, polar=True) fig.add_axes(rect, projection='polar') fig.add_axes(ax) # add an Axes instance If the figure already has an axes with the same parameters, then it will simply make that axes current and return it. If you do not want this behavior, eg. you want to force the creation of a new axes, you must use a unique set of args and kwargs. The axes :attr:`~matplotlib.axes.Axes.label` attribute has been exposed for this purpose. Eg., if you want two axes that are otherwise identical to be added to the figure, make sure you give them unique labels:: fig.add_axes(rect, label='axes1') fig.add_axes(rect, label='axes2') The :class:`~matplotlib.axes.Axes` instance will be returned. The following kwargs are supported: %(Axes)s Nitpolart projections!polar=True, yet projection='%s'. s/Only one of these arguments should be supplied.(RRtscaRbt isinstanceRRRhR-R/RRSRRRtpush( RRRR3RnRtrecttispolarR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytadd_axes-s4&        s, tlistRc Os~|i}t|pdSt|dto|d}n|idt}|idd}|o<|dj o%|djotdd|nd}nt|}|i ||}||i joS|i |}t||o|i ||S|i i ||ii |nt||||}||i |<|i i||ii||i ||S(sC Add a subplot. Examples: fig.add_subplot(111) fig.add_subplot(1,1,1) # equivalent but more general fig.add_subplot(212, axisbg='r') # add subplot with red background fig.add_subplot(111, polar=True) # add a polar subplot fig.add_subplot(sub) # add Subplot instance sub *kwargs* are legal :class:`!matplotlib.axes.Axes` kwargs plus *projection*, which chooses a projection type for the axes. (For backward compatibility, *polar=True* may also be provided, which is equivalent to *projection='polar'*). Valid values for *projection* are: %(list)s. Some of these projections support additional *kwargs*, which may be provided to :meth:`add_axes`. The :class:`~matplotlib.axes.Axes` instance will be returned. If the figure already has a subplot with key (*args*, *kwargs*) then it will simply make that subplot current and return it. The following kwargs are supported: %(Axes)s NiRRs!polar=True, yet projection='%s'. s/Only one of these arguments should be supplied.(tcopyRbRRRRhR-R/RRRRRSRRRRRR( RRRRRRtprojection_classR3Rn((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt add_subplotvs<         cCsd|_tid|_x.t|iD]}|i|i|q+Wt |i dd}|dj o|i n|i i h|_g|_g|_g|_g|_g|_g|_g|_dS(s" Clear the figure R<ttoolbarN(s dpi_changed(R-tsuppressCompositeRCRDRER8RStclaRR,RPRRRRYRRsRtRuRvRwRxR(RRnR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRTs$           cCs|idS(s9 Clear the figure -- synonym for fig.clf N(RT(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRYscCs|ipdS|id|io|ii|nx|iD]}|i|qGWx|iD]}|i|qhWx|iD]}|i|qW|i}|i dj o |i }nt |i djp6|p/t g}|i D]}||iq~ o%x|i D]}|i|qWn|i}g} |i D]%}| |i||i|ifqT~ } ti|ii||ii|| }t|_|ii\}} } } |i\}}|i|| ||i||x|iD]}|i|qWx|iD]}|i|q(Wx|iD]}|i|qIW|i d||_!|i"i#|dS(sj Render the figure using :class:`matplotlib.backend_bases.RendererBase` instance renderer Ntfigurei($t get_visiblet open_groupRJRLtdrawRuRtRstoption_image_nocompositeRR-RbRwRRtget_image_magnificationt make_imagetoxtoyt_imaget from_imagesR9R?R>Rht is_grayscaletboundst$get_transformed_clip_path_and_affinet draw_imageRSRvRxt close_groupRURPt draw_event(RtrenderertptlRt compositeRmRtmagt_[2]timsRRRtclippathtaffineRtlegend((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRsX        L  5         cCs|i|idS(s draw :class:`matplotlib.artist.Artist` instance *a* only -- this is available only after the figure is drawn N(RRU(RR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt draw_artistscCs|iS(N(RS(R((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRfscOs8t|}t|||||}|ii||S(s2 Place a legend in the figure. Labels are a sequence of strings, handles is a sequence of :class:`~matplotlib.lines.Line2D` or :class:`~matplotlib.patches.Patch` instances, and loc can be a string or an integer specifying the legend location USAGE:: legend( (line1, line2, line3), ('label1', 'label2', 'label3'), 'upper right') The *loc* location codes are:: 'best' : 0, (currently not supported for figure legends) 'upper right' : 1, '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, *loc* can also be an (x,y) tuple in figure coords, which specifies the lower left of the legend box. figure coords are (0,0) is the left, bottom of the figure and 1,1 is the right, top. Keyword arguments: *prop*: [ None | FontProperties | dict ] A :class:`matplotlib.font_manager.FontProperties` instance. If *prop* is a dictionary, a new instance will be created with *prop*. If *None*, use rc settings. *numpoints*: integer The number of points in the legend line, default is 4 *scatterpoints*: integer The number of points in the legend line, default is 4 *scatteroffsets*: list of floats a list of yoffsets for scatter symbols in legend *markerscale*: [ None | scalar ] The relative size of legend markers vs. original. If *None*, use rc settings. *fancybox*: [ None | False | True ] if True, draw a frame with a round fancybox. If None, use rc *shadow*: [ None | False | True ] If *True*, draw a shadow behind legend. If *None*, use rc settings. *ncol* : integer number of columns. default is 1 *mode* : [ "expand" | None ] if mode is "expand", the legend will be horizontally expanded to fill the axes area (or *bbox_to_anchor*) *title* : string the legend title Padding and spacing between various elements use following keywords parameters. The dimensions of these values are given as a fraction of the fontsize. Values from rcParams will be used if None. ================ ================================================================== Keyword Description ================ ================================================================== borderpad the fractional whitespace inside the legend border labelspacing the vertical space between the legend entries handlelength the length of the legend handles handletextpad the pad between the legend handle and text borderaxespad the pad between the axes and legend border columnspacing the spacing between columns ================ ================================================================== **Example:** .. plot:: mpl_examples/pylab_examples/figlegend_demo.py (RRRxR(RthandlestlabelsRRR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRsY cOs[th||}td|d|d|}|i||i||ii||S(sT Call signature:: figtext(x, y, s, fontdict=None, **kwargs) Add text to figure at location *x*, *y* (relative 0-1 coords). See :func:`~matplotlib.pyplot.text` for the meaning of the other arguments. kwargs control the :class:`~matplotlib.text.Text` properties: %(Text)s R~RR(RR RRNRvR(RR~RR1RRtoverrideR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyR|s  cCs2||jo|i|n|i|idS(N(t set_figuret set_transformRK(RR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRNs cKs|i}|dj o|idt}|idd}|o<|dj o%|djotdd|nd}nt|}t||o|Sn|id|S(s Return the current axes, creating one if necessary The following kwargs are supported %(Axes)s RRs!polar=True, yet projection='%s'. s/Only one of these arguments should be supplied.ioN(RRR-RRhR/RRR(RRRnRRR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytgcas     cCs2|ii|x|iD]}||qW|S(s)Set the current axes to be a and return a(RRtbubbleR(RRR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRs  cCs|ii|dS(s9whenever the axes state change, func(self) will be calledN(RR(RR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytadd_axobserversc Osx1dD])}||jotd||||iD]/}|i}|i|i|idq|Wn|ii |||oG|ii|x4t |i|D]\}} |ii| qWndS( s call signature:: savefig(fname, dpi=None, facecolor='w', edgecolor='w', orientation='portrait', papertype=None, format=None, transparent=False): Save the current figure. The output formats available depend on the backend being used. Arguments: *fname*: A string containing a path to a filename, or a Python file-like object. If *format* is *None* and *fname* is a string, the output format is deduced from the extension of the filename. Keyword arguments: *dpi*: [ None | scalar > 0 ] The resolution in dots per inch. If *None* it will default to the value ``savefig.dpi`` in the matplotlibrc file. *facecolor*, *edgecolor*: the colors of the figure rectangle *orientation*: [ 'landscape' | 'portrait' ] not supported on all backends; currently only on postscript output *papertype*: One of 'letter', 'legal', 'executive', 'ledger', 'a0' through 'a10', 'b0' through 'b10'. Only supported for postscript output. *format*: One of the file extensions supported by the active backend. Most backends support png, pdf, ps, eps and svg. *transparent*: If *True*, the figure patch and axes patches will all be transparent. This is useful, for example, for displaying a plot on top of a colored background on a web page. The transparency of these patches will be restored to their original values upon exit of this function. *bbox_inches*: Bbox in inches. Only the given portion of the figure is saved. If 'tight', try to figure out the tight bbox of the figure. *pad_inches*: Amount of padding around the figure when bbox_inches is 'tight'. RGR@RAs savefig.%st transparentgN(sdpis facecolors edgecolor( R RRhRLt get_alphaRRSRRPt print_figuretzip( RRRR3Rtoriginal_figure_alphatoriginal_axes_alphaRnRLR((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytsavefigs(;    c s|djo|i}n|djoti||\}}n|itti|||fd}|iid||_ |i ||i |S(Ncs7i|ii|ii|dS(N(tset_cmaptget_cmapRtget_climtupdate_bruteforce(tm(tcb(sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt on_changedstchanged( R-Rtcbart make_axesRRtColorbart callbacksSMtconnecttcbidt set_colorbarR(RtmappabletcaxRntkwR((R sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytcolorbars    s Create a colorbar for a ScalarMappable instance. Documentation for the pylab thin wrapper: %s cOs|ii||ddk}x|iD]}t||iip|idj o=t|i|iio$|ii|i |ii q|i dj o=t|i |iio$|i i|i |i i qq)|i|i |i q)WdS(s fig.subplots_adjust(left=None, bottom=None, right=None, top=None, wspace=None, hspace=None) Update the :class:`SubplotParams` with *kwargs* (defaulting to rc where None) and update the subplot locations iN( RQRtmatplotlib.axesRSRRt_sharexR-t update_paramst set_positiontfigboxt_sharey(RRRt matplotlibRn((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyRj)s   ) )  iiicCs7t|d|d|d|}|d|d|d|S(s call signature:: ginput(self, n=1, timeout=30, show_clicks=True, mouse_add=1, mouse_pop=3, mouse_stop=2) Blocking call to interact with the figure. This will wait for *n* clicks from the user and return a list of the coordinates of each click. If *timeout* is zero or negative, does not timeout. If *n* is zero or negative, accumulate clicks until a middle click (or potentially both mouse buttons at once) terminates the input. Right clicking cancels last input. The buttons used for the various actions (adding points, removing points, terminating the inputs) can be overriden via the arguments *mouse_add*, *mouse_pop* and *mouse_stop*, that give the associated mouse button: 1 for left, 2 for middle, 3 for right. The keyboard can also be used to select points in case your mouse does not have one or more of the buttons. The delete and backspace keys act like right clicking (i.e., remove last point), the enter key terminates input and any other key (not already used by the window manager) selects a point. t mouse_addt mouse_popt mouse_stoptnttimeoutt show_clicks(R(RR%R&R'R"R#R$tblocking_mouse_input((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytginputAs  icCst|}|d|S(sd call signature:: waitforbuttonpress(self, timeout=-1) Blocking call to interact with the figure. This will return True is a key was pressed, False if a mouse button was pressed and None if *timeout* was reached without either being pressed. If *timeout* is negative, does not timeout. R&(R(RR&tblocking_input((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pytwaitforbuttonpressgs c Csg}x8|iD]-}|io|i|i|qqWtig}|D]1}|idjp|idjo ||qRqR~}t|t i d|i }|S(s Return a (tight) bounding box of the figure in inches. It only accounts axes title, axis labels, and axis ticklabels. Needs improvement. ig?( RSRRt get_tightbboxRtunionR>R?RRRZRG(RRtbbRnRmRt_bboxRI((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyR,{s  NN(?R4R5R6R;R-RR$RXR\tpropertyRGRqRzR}RRRRRRRRRRRRRRRRRRRRRRRR tjoinRtartisttkwdocdRRTRYRRRRfRRRNRRRRRRt colorbar_docRjR)R+R,(((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyR7vs  9  $  $   >  &               E  A  :   ^      P & c Cst|d}tid }tid }|o'|id \}}t||}n t|}tdd}ti|||f}|td||:}|td||:}ti|||}|S( s; Create a figure with specified aspect ratio. If *arg* is a number, use that aspect ratio. If *arg* is an array, figaspect will determine the width and height for a figure that would fit array preserving aspect ratio. The figure width, height in inches are returned. Be sure to create an axes with equal with and height, eg Example usage:: # make a figure twice as tall as it is wide w, h = figaspect(2.) fig = Figure(figsize=(w,h)) ax = fig.add_axes([0.1, 0.1, 0.8, 0.8]) ax.imshow(A, **kwargs) # make a figure with the proper aspect for an array A = rand(5,3) w, h = figaspect(A) fig = Figure(figsize=(w,h)) ax = fig.add_axes([0.1, 0.1, 0.8, 0.8]) ax.imshow(A, **kwargs) Thanks to Fernando Perez for this function tshapeg@g@g0@isfigure.figsizeig?(g@g@(g0@g0@( RaR_tarrayR5tfloatR tmintmaxtclip( targtisarrayt figsize_mint figsize_maxtnrtnct arr_ratiot fig_heighttnewsize((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt figaspects (0R6tnumpyR_R2RRRSRRRRCRRRRR RRRtimageR R!R RuR RR RRRt transformsRRRRt projectionsRRRtmatplotlib.blocking_inputRRtmatplotlib.cbookRR7RDtkwdocR3(((sD/opt/alt/python27/lib64/python2.7/site-packages/matplotlib/figure.pyt s0  (  "R >