[SciPy-dev] help with xplot->matplotlib translation

Travis E. Oliphant oliphant@enthought....
Tue Dec 23 15:02:56 CST 2008


josef.pktd@gmail.com wrote:
> stats.morestats contains several function creating plots with xplot
>
>     if plot is not None:
>         try:
>             import scipy.xplt as xplt
>             xplt.limits()
>         except: pass
>         plot.plot(svals, ppcc, 'x')
>         plot.title('(%s) PPCC Plot' % dist)
>         plot.xlabel('Prob Plot Corr. Coef.'),deltay=-0.01)
>         plot.ylabel('Shape Values'),deltax=-0.01)
>         try: plot.expand_limits(5)
>         except: pass
>
> I would like to translate this to using plot=matplotlib.pylab, but I
> don't know anything about xplt and I am not very good with matplotlib.
>
> So, if someone familiar with these, can provide a translation for
> xplt.limits(), deltay=-0.01, deltax and expand_limits, then I could
> fix these bugs without hunting documentation for hours. If I delete
> deltay and deltax, then the function works, but I don't know if I get
> the indended graph.
>
>   
deltax and deltay are just terms to move the placement of text in the 
horizontal and vertical direction.   You can delete them without any 
concern. 

The expand_limits function can also be removed without concern as it is 
another "formatting" piece that tries and makes the graph look more 
pleasing.

Thanks for fixing things.

-Travis



More information about the Scipy-dev mailing list