|
From: Bernhard V. <ber...@gm...> - 2007-10-25 08:56:20
|
A simple solution would be: numbers, text = yticks() mytext = ['%.2f' % n for n in numbers] yticks(numbers, mytext) If you need fancier formatting look at Ticker and Formatter API http://matplotlib.sourceforge.net/matplotlib.ticker.html For sure there's something about this in the examples as well. Best! Bernhard On 10/23/07, pyt...@ma... <pyt...@ma...> wrote: > > Hi guys. > I'm just a newbie at matplotlib. I couldn't find the answer on my > quistion in project's docs. > I've wrote the following code: > from pylab import * > semilogy([1, 5, 2, 3, 1, 6], basey=2) > show() > > > It works OK but I'd like to see usual decimal numbers instead of 2^0, > 2^1, 2^2 ... on y axis. > How can I do that? > Thnx. > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > |