[R] Font size in plots (I do NOT understand par help)
Peter Dalgaard
p.dalgaard at biostat.ku.dk
Wed Aug 6 16:56:58 CEST 2008
Stephane Bourgeois wrote:
> Hi,
>
>
>
> I do not get how par works, help please.
>
>
>
> Let's say I have a simple plot: plot(1:10)
>
>
>
> I want to change the font size for the x axis... how do I do that?
>
Well, you start by reading help(par) multiple times, and then play
around....
Start with, e.g.
plot(1:10, cex.axis=2)
The problem with that is that it controls the y axis too, so
plot(1:10, cex.axis=2, yaxt="n")
axis(2)
or vice versa
plot(1:10, xaxt="n")
axis(1, cex.axis=2)
If you didn't actually mean the values, consider similar techniques
involving cex.lab or cex.sub and the title() function.
--
O__ ---- Peter Dalgaard Øster Farimagsgade 5, Entr.B
c/ /'_ --- Dept. of Biostatistics PO Box 2099, 1014 Cph. K
(*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907
More information about the R-help
mailing list