On 08/19/2010 05:53 PM, Friedrich Romstedt wrote: > 2010/8/19 Michael Droettboom<md...@stsci.edu>: > >> On 08/18/2010 06:03 PM, Friedrich Romstedt wrote: >> >>> Is the attached issue with a plain polar axes already fixed? I never >>> encountered this before. 344 degrees happens to be 6.0 rad. I'm on >>> svn 8626. >>> >> How are you creating that graph? By default, polar plots don't do that. >> > Yeah, it's my issue, but I'm not happy with fixing it. Currently, > matplotlib forces the xticks (i.e., the theta ticks) to be at sensible > values via .set_xticks() and .set_xlabels() (projections/polar.py). > > I'm coding a matplotlib extension package which has to clear the axes > often, but restoring the major locators, the title and stuff after > clearing. It was agnostic to the specialities of polar axes so far. > Why and how are you restoring the major locator? It seems like that's the issue. I don't think preventing the theta locator from being changed is something we want to do. Polar plots (by default) just set fixed theta ticks at multiples of pi/4. > I would rather suggest to insert a new Locator class being aware of > radians. It would suffice to return tick positions dividing 2 pi into > an integer number of bins. It's not necessary to cover all the > peculiarities of the old historic division system into 360 parts. > Perhaps using FixedLocator, rather than explicitly setting the ticks using set_xticks (as polar plots currently do) would be better. However, the locator could still be changed, not really addressing your problem.
For convenience, however, we could add a locator that given n, divides 2pi into n parts. > Accompanying would be formatters in radians and degrees with > adjustable precision (no autodetect necessary). > Sure. Adding a radian formatter makes sense. Mike -- Michael Droettboom Science Software Branch Space Telescope Science Institute Baltimore, Maryland, USA ------------------------------------------------------------------------------ This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users