[EMAIL PROTECTED] writes: > The method proposed by Jouni appears to work too: > gca().yaxis.set_major_locator(LinearLocator()) > but it created too many labels.
It's just the default behavior. Please see http://matplotlib.sourceforge.net/matplotlib.ticker.html#LinearLocator or simply query the documentation of LinearLocator in ipython: | Constructor information: | Definition: LinearLocator(self, numticks=None, presets=None) | Docstring: | Use presets to set locs based on lom. A dict mapping vmin, vmax->locs The docstring is kind of cryptic (what's a lom?) but the numticks keyword argument hints that you can set the number of ticks, e.g. gca().yaxis.set_major_locator(LinearLocator(numticks=4)) But, as John said, if you already know where you want the ticks, you can just set them directly. -- Jouni K. Seppänen http://www.iki.fi/jks ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users