rL i1 LdZddlZddlmZdgZGddej Zy)z2StrConverter module containing class StrConverter.N StrConverterc@eZdZdZedZedZedZy)ral A Matplotlib converter class for string data values. Valid units for string are: - 'indexed' : Values are indexed as they are specified for plotting. - 'sorted' : Values are sorted alphanumerically. - 'inverted' : Values are inverted so that the first value is on top. - 'sorted-inverted' : A combination of 'sorted' and 'inverted' cy)N)unitaxiss o/mnt/ssd/data/python-lab/Trading/venv/lib/python3.12/site-packages/matplotlib/testing/jpl_units/StrConverter.pyaxisinfozStrConverter.axisinfosc|gk(rgS|j}||jurd}nd}|j|j}|j }|Dcgc]#}|j s|j %}}|sg}g}t j|s|g}g}|D]} | |vs| |vs |j| |j|dg|zdgz}ttt|}d|d<|ddz |d<|j||j||j} | j!|d|d|r|j#|d|dn|j%|d|d|D cgc]} ||j'| } } |j(j+d| Scc}wcc} w)NTFg?r)axesxaxisget_major_ticks get_ticklocsget_ticklabelsget_textnpiterableappendextendlistrangelen set_ticksset_ticklabelsget_major_locator set_boundsset_xlimset_ylimindexviewLimignore) valuerraxisXAxistickslabelsl newValuesvlocresults r convertzStrConverter.converts B;IYY 288 GG !!#$$&(.?1!**,!**,??EF{{5!GE  $A1I#5  # $  i "%U3v;'(a"IOb  u F#$$& uQxr+  KKa%) , KKa%) ,278Q% Q(88 " _@X9sG 1G Gcy)Nindexedr)r%rs r default_unitszStrConverter.default_units]sr N)__name__ __module__ __qualname____doc__ staticmethodr r/r2rr r rr sF@@Dr )r6numpyrmatplotlib.unitsunits__all__ConversionInterfacerrr r r=s*8  W5,,Wr