KGRKJGETMRETU895U-589TY5MIGM5JGB5SDFESFREWTGR54TY
Server : Apache
System : Linux server112.speedpacket.com 3.10.0-962.3.2.lve1.5.36.el7.x86_64 #1 SMP Mon May 18 02:16:06 EDT 2020 x86_64
User : equistyl ( 1341)
PHP Version : 8.1.30
Disable Function : NONE
Directory :  /lib64/python2.7/site-packages/matplotlib/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //lib64/python2.7/site-packages/matplotlib/spines.pyo
�
r`]c@ s�ddlmZmZddlZejZddljZddlmZddlm	Z	ddl
jZddl
jZddljZddljZddljZddlZddlZdejfd��YZdS(i����(tdivisiontprint_functionN(tallow_rasterization(t	docstringtSpinecB seZdZd�Zejd��Zd�Zd�Zd�Z	d�Z
d�Zd�Zd	�Z
d
�Zd�Zd�Zd
�Zd�Zed��Zd�Zd�Zd�Zd�Zd�Zd�Zed��Zed��Zd�ZRS(s�an axis spine -- the line noting the data area boundaries

    Spines are the lines connecting the axis tick marks and noting the
    boundaries of the data area. They can be placed at arbitrary
    positions. See function:`~matplotlib.spines.Spine.set_position`
    for more information.

    The default position is ``('outward',0)``.

    Spines are subclasses of class:`~matplotlib.patches.Patch`, and
    inherit much of their behavior.

    Spines draw a line or a circle, depending if
    function:`~matplotlib.spines.Spine.set_patch_line` or
    function:`~matplotlib.spines.Spine.set_patch_circle` has been
    called. Line-like is the default.

    cC sdS(NR((tself((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt__str__$scK s�tt|�j|�||_|j|jj�||_|jd�|jt	d�|j
t	d�d|_|j
d�|j|jj�d|_t|_d|_||_d|_tj�|_dS(s�
        - *axes* : the Axes instance containing the spine
        - *spine_type* : a string specifying the spine type
        - *path* : the path instance used to draw the spine

        Valid kwargs are:
        %(Patch)s
        tnonesaxes.edgecolorsaxes.linewidthg@tlineN(tsuperRt__init__taxest
set_figuretfiguret
spine_typet
set_facecolort
set_edgecolortrcParamst
set_linewidthtNonetaxist
set_zordert
set_transformt	transDatat_boundstFalset
_smart_boundst	_positiont_patht_patch_typetmtransformstIdentityTransformt_patch_transform(RRRtpathtkwargs((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyR
's 
		
	
					cC sW||_|jdkr.|jjj|�n%|jdkrS|jjj|�ndS(s6set the spine and associated axis to have smart boundstlefttrightttoptbottomN(R#R$(stopR&(RRRtyaxistset_smart_boundstxaxis(Rtvalue((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyR(Rs
	cC s|jS(s&get whether the spine has smart bounds(R(R((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pytget_smart_bounds\scC sLd|_||_|d|_|d|_d|_|j|jj�dS(sset the spine to be circulartcircleiiN(Rt_centert_widtht_heightt_angleRRt	transAxes(Rtcentertradius((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pytset_patch_circle`s		

	cC s
d|_dS(sset the spine to be linearRN(R(R((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pytset_patch_lineiscC s�|j|jd�|j|jd�f}|j|j�}|j|j�}tj�j|d|d�j|j	�j
|�|_dS(sNOTE: This cannot be called until after this has been added
                 to an Axes, otherwise unit conversion will fail. This
                 maxes it very important to call the accessor method and
                 not directly access the transformation member variable.
        iig�?N(tconvert_xunitsR-tconvert_yunitsR.R/RtAffine2Dtscalet
rotate_degR0t	translateR (RR2twidththeight((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt_recompute_transformnscC s7|jdkr |j�|jStt|�j�SdS(NR,(RR>R R	Rtget_patch_transform(R((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyR?~s
cC s|jS(N(R(R((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pytget_path�scC s/|jdkr+d|_|j|j�ndS(Ntoutwardg(RAg(RRtset_position(R((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt_ensure_position_is_set�s	cC s,||_|jdk	r(|jj�ndS(s�register an axis

        An axis should be registered with its corresponding spine from
        the Axes instance. This allows the spine to clear any axis
        properties when needed.
        N(RRtcla(RR((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt
register_axis�s	cC s,d|_|jdk	r(|jj�ndS(sClear the current spineN(RRRRD(R((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyRD�s	cC s|j�|j}tj|�rO|dkr7d	}qO|dkrOd
}qOn|\}}|dkrw|dkrwtStSdS(s�return True if directly on axes frame

        This is useful for determining if a spine is the edge of an
        old style MPL plot. If so, this function will return True.
        R2Rg�?tzerotdataiRAN(saxesg�?(sdatai(RCRtcbooktis_string_liketTrueR(Rtpositiont
position_typetamount((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt
is_frame_like�s
		cC s�|jdkrdS|jdkr3|jdkrI|jjj\}}n:|jd
krp|jjj\}}ntd|j��|jrB||kr�||}}n|}|}~~|jdkr�|jj	j\}}|jj
�}n6|jdkr&|jj	j\}}|jj�}nt|�}|j
�tj|�}||krg||}}n||kr||}nN||k||k@}||}	t|	�r�|	d}n|}t||�}||kr�|}q0||k||k@}||}	t|	�r|	d	}n|}t||�}qBn|j\}}|jj}
|jdkrt||
d<||
d<n6|jdkr�||
d<||
d<ntdt��dS(s3automatically set spine bounds to the view intervalR,NR#R$R%R&sunknown spine spine_type: %si����iis#unable to set bounds for spine "%s"(sleftsright(stopsbottom(sleftsright(stopsbottom(sleftsright(ii(ii(sbottomstop(ii(ii(RRRRtviewLimt	intervalyt	intervalxt
ValueErrorRtdataLimt
get_ytickst
get_xtickstlisttsorttnptarraytlentmaxtminRtvertices(Rtlowthightviewlim_lowtviewlim_hightdatalim_lowtdatalim_highttickstcondttickvalstv1((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt_adjust_location�sd	
	

	





cC s |j�tt|�j|�S(N(RhR	Rtdraw(Rtrenderer((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyRis
cC s�|j�|j}tj|�rO|dkr7d}qO|dkrOd}qOn|\}}|dkr:|dkr�dtj�f|_q�|jdkridd	6dd
6dd6dd6|j}||dd}||dd}dtj|||j	j
�f|_q�tjd|j�dtj�f|_nN|dkr�|jdkr�dtj
jdddd|d�f|_q�|jdkr�dtj
jddddd|�f|_q�tjd|j�dtj�f|_n�|dkr�|jdkr)dtj
�j|d�f|_q�|jdkr\dtj
�jd|�f|_q�tjd|j�dtj�f|_ndS(s5calculate the offset transform performed by the spineR2Rg�?RFRGiRAtidentityR#R$R%R&i����igR@tposts2unknown spine type "%s": no spine offset performedtpreN(saxesg�?(sdatai(sleftsrightstopsbottom(i����i(ii(ii����(ii(sleftsright(sbottomstop(sleftsright(sbottomstop(RCRRHRIRRt_spine_transformRtScaledTranslationR
tdpi_scale_transtwarningstwarnR8tfrom_valuesR;(RRKRLRMt
offset_vectoffset_xtoffset_y((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt_calc_offset_transform
s^
		

		!	!	!!	cC s�|dkrn||_|j�|j�}|jd	krXtj||jj�}n*|jd
kr�tj|jj|�}n|j|�|j	dk	r�|j	j�ndS(spset the position of the spine

        Spine position is specified by a 2 tuple of (position type,
        amount). The position types are:

        * 'outward' : place the spine out from the data area by the
          specified number of points. (Negative values specify placing the
          spine inward.)

        * 'axes' : place the spine at the specified Axes coordinate (from
          0.0-1.0).

        * 'data' : place the spine at the specified data coordinate.

        Additionally, shorthand notations define a special positions:

        * 'center' -> ('axes',0.5)
        * 'zero' -> ('data', 0.0)

        R2RFR#R$R&R%N(scenterszero(sleftsright(sbottomstop(RRwtget_spine_transformRRtblended_transform_factoryRRRRRRD(RRKtttt2((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyRBEs	
	
cC s|j�|jS(sget the spine position(RCR(R((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pytget_positionos
cC sa|j�|j\}}|dkr�|jj||jj|jj}|jdkrstj||jj	�}n=|jdkr�tj|jj	|�}nt
d|j��|S|jdkr�|jjdd�}n:|jdkr|jjdd�}nt
d|j��|d	kr%|S|d
kr9||S|dkrM||St
d|��d
S(sget the spine transformRGR#R$R%R&sunknown spine spine_type: %stwhichtgridRkRlRms unknown spine_transform type: %sN(sleftsright(stopsbottom(sleftsright(stopsbottom(
RCRnRt
transScalettransLimitsR1RRRyRRRtget_yaxis_transformtget_xaxis_transform(Rtwhatthowt
data_xformtresulttbase_transform((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyRxts2
	cC s1|jdkrtd��n||f|_dS(sSet the bounds of the spine.R,s5set_bounds() method incompatible with circular spinesN(RRRR(RR^R_((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt
set_bounds�scC s|jS(sGet the bounds of the spine.(R(R((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt
get_bounds�scK s�|dkr$tjd	d
g�}n||dkrHtjddg�}nX|dkrltjd
dg�}n4|dkr�tjddg�}ntd|��|||||�}|S(sA
        (staticmethod) Returns a linear :class:`Spine`.
        R#gi
R$g�?R&R%s"unable to make path for spine "%s"(gi
(gi
(g�?i
(g�?i
(i
g(i
g(i
g�?(i
g�?(tmpathtPathRR(tclsRRR"R!R�((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pytlinear_spine�scK s>tjj�}d}|||||�}|j||�|S(sC
        (staticmethod) Returns a circular :class:`Spine`.
        R,(R�R�tunit_circleR4(R�RR2R3R"R!RR�((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pytcircular_spine�s
cC s|j|�dS(s�
        Set the edgecolor.

        ACCEPTS: matplotlib color arg or sequence of rgba tuples

        .. seealso::

            :meth:`set_facecolor`, :meth:`set_edgecolor`
               For setting the edge or face color individually.
        N(R(Rtc((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt	set_color�s
(t__name__t
__module__t__doc__RRtdedent_interpdR
R(R+R4R5R>R?R@RCRERDRNRhRRiRwRBR|RxR�R�tclassmethodR�R�R�(((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyRs2	+	
												R	;	*		#		(t
__future__RRt
matplotlibRtmatplotlib.artisttartisttmartistRRtmatplotlib.transformst
transformsRtmatplotlib.linestlinestmlinestmatplotlib.patchestpatchestmpatchestmatplotlib.pathR!R�tmatplotlib.cbookRHtnumpyRXRqtPatchR(((s7/usr/lib64/python2.7/site-packages/matplotlib/spines.pyt<module>s	

Anon7 - 2021