From: John Hunter <jdh2358@gm...> - 2008-10-10 12:50:03
On Fri, Oct 10, 2008 at 4:17 AM, Thomas Guettler <hv@...> wrote:
> I want to change the font size of x ticks labels.
> The FAQ entry is only for pylab:
> I found this solution:
> for tick in ax.xaxis.get_major_ticks():
> What is the prefered way? Maybe without a loop...
There is no preferred way -- the loop is the object oriented pythonic
matplotlib API, the set call is the matlab-like procedural interface.
Both are and will continue to be supported. Note that the FAQ is out
of date since the set function (a matlab name) is now called setp to
avoid clashing with the python built-in set
Personally, I use
for label in ax.get_xticklabels() + ax.get_yticklabels():
You can also set the defaults with your rc settings
which will affect all subsequent figures.
Get latest updates about Open Source Projects, Conferences and News.