Fontsize of tick labels

Is there any way of conveniently changing the font size of tick labels using the object-oriented interface?

I'm aware of plt.xticks(fontsize=6), which does this globally for a figure, but if I have a number of custom axes of which I only want to change the tick-fontsize of a selected few, I've only been able to come up with
      ax1.xaxis.set_ticklabels([0,1,2,3,4,5], fontsize=6)
This involves manually specifying the tick labels. However, I'm perfectly happy with the labels as supplied by ScalarFormatter and only want to change the font size. How to do this?

Regards
Johann

Is there any way of conveniently changing the font size of tick labels using
the object-oriented interface?

I'm aware of plt.xticks(fontsize=6), which does this globally for a figure,
but if I have a number of custom axes of which I only want to change the
tick-fontsize of a selected few, I've only been able to come up with
           ax1.xaxis.set_ticklabels([0,1,2,3,4,5], fontsize=6)
This involves manually specifying the tick labels. However, I'm perfectly
happy with the labels as supplied by ScalarFormatter and only want to change
the font size. How to do this?

    for t in ax1.get_xticklabels():
        t.set_fontsize(6.)

Or with matplotlib.artist.setp function,

    setp(ax1.get_xticklabels(), fontsize=6)

-JJ

···

On Mon, Feb 23, 2009 at 3:06 PM, Johann Rohwer <jr@...841...> wrote:

Regards
Johann

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users