I'm creating a twined axes figure and have run into a problem. I need
to increase the font size of all the text on the plot, but nothing I do
seems to work.
Here's the code I have to generate the plot:
> fig = figure()
> host = HostAxes(fig,[0.08, 0.1, 0.82, 0.83])
> par = ParasiteAxes(host,sharex=host)
> host.parasites.append(par)
> host.set_xlabel('Dominant Characteristic Threshold')
> host.axis['right'].set_visible(False)
> par.axis['right'].set_visible(True)
> host.set_ylabel('Number of Groups')
> par.set_ylabel('% Noise Students')
> par.axis["right"].major_ticklabels.set_visible(True)
> par.axis["right"].label.set_visible(True)
> fig.add_axes(host)
> p1, = par.plot(dom[-1],noise[-1],'-o')
> p2, = host.plot(dom[-1],ngroups[-1],'-s')
> p3, = par.plot([75,100],[.1,.1],'--',color=p1.get_color(),alpha=0.5)
> p4, = par.plot([75,100],[.2,.2],'--',color=p1.get_color(),alpha=0.5)
> p5, = par.plot([75,100],[.3,.3],'--',color=p1.get_color(),alpha=0.5)
> p6, = par.plot([75,100],[.4,.4],'--',color=p1.get_color(),alpha=0.5)
> p7, = par.plot([75,100],[.5,.5],'--',color=p1.get_color(),alpha=0.5)
> p8, = par.plot([75,100],[.6,.6],'--',color=p1.get_color(),alpha=0.5)
> p9, = par.plot([75,100],[.7,.7],'--',color=p1.get_color(),alpha=0.5)
> p10, = par.plot([75,100],[.8,.8],'--',color=p1.get_color(),alpha=0.5)
> host.set_ylim(0,8)
> par.set_ylim(0,0.9)
> host.axis["left"].label.set_color(p2.get_color())
> par.axis["right"].label.set_color(p1.get_color())
> draw()
> filename = 'Figures/%idomthreshold.png' % aa
> savefig(filename,dpi=150)
Things I've tried:
Adding a size keyword argument to the set_xlabel and set_ylabel commands
(both numerical and keywords). No errors are raised, but nothing is
changed on the plot.
Adding host.axis["left"].set_size(24) and
par.axis["right"].set_size('large'), to the code. This raises an
AttributeError: 'AxisArtist' object has no attribute 'set_size'
Adding host.set_size(24) and par.set_size('large') to the code. This
raises an AttributeError: 'AxesHostAxes' object has no attribute 'set_size'
Any suggestions for how to get the font size larger?
--
R. Padraic Springuel
Research Assistant
Department of Physics and Astronomy
University of Maine
Bennett 309
Office Hours: By Appointment Only
------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://p.sf.net/sfu/dev2dev-palm
_______________________________________________
Matplotlib-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-users