Jae-Joon Lee wrote:
>
> get_xmajorticklabels() returns a list of matplotlib's "Text" objects,
> not python strings.
>
This is what I've now come to understand, but it seems very odd. Why
wouldn't it return the list of strings, or alternatively, how can you get
the list of strings? I guess you have to use the pyplot tools, but I was
trying to use so called 'fine grain' control and do everything at the axes
level.
>
> plt.setp(plt.gca().get_xmajorticklabels(),
> size=6,rotation=30)
>
In fact, what you show is how I was testing in ipython and it does worked,
it just seemed in a script it would be better to use the axis method, but
apparently it is different from the gca() method. This is what I don't
understand.
Thanks!
On Mon, Jul 20, 2009 at 11:48 AM, John [H2O]<washa...@gmail.com> wrote:
>
> I am trying simply to shrink the font size and rotate xaxis labels:
>
> fig1 = plt.figure()
> ax1 = fig1.add_subplot(211)
> ax2 = fig1.add_subplot(212)
> ax1.plot_date(x,y,'r')
> ax1.set_xticklabels(plt.gca().get_xmajorticklabels(),
> size=6,rotation=30)
> ax2.plot_date(o_X['time'],o_X['CO'],'y')
> ax2.set_xticklabels(plt.gca().get_xmajorticklabels(),
> size=6,rotation=30)
>
> I end up with labels as: ("Text(0,0"Text(0,0,"")")
>
> ????
> --
> View this message in context:
> http://www.nabble.com/rotating-labels%2C-what-is-wrong-%21-tp24572302p24572302.html
> Sent from the matplotlib - users mailing list archive at Nabble.com.
>
>
> ------------------------------------------------------------------------------
> Enter the BlackBerry Developer Challenge
> This is your chance to win up to $100,000 in prizes! For a limited time,
> vendors submitting new applications to BlackBerry App World(TM) will have
> the opportunity to enter the BlackBerry Developer Challenge. See full
> prize
> details at: http://p.sf.net/sfu/Challenge
> _______________________________________________
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users
--
View this message in context:
http://www.nabble.com/rotating-labels%2C-what-is-wrong-%21-tp24572302p24577287.html
Sent from the matplotlib - users mailing list archive at Nabble.com.
------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users