[R] xyplot main title question
dieter.menne at menne-biomed.de
Sun Sep 25 20:32:55 CEST 2005
Pogoda, Wendy <wpogoda <at> coba.usf.edu> writes:
> When I use the xyplot function (lattice library) the titles are too long
How can I change the main title text size in the xyplot function? .
This IS confusing. General rule: whenever you use a function from
lattice/trellis, par(...) is the wrong way to go. Use trellis.par.get and
trellis.par set instead.
mt = trellis.par.get("par.main.text")
mt$cex = 0.7
# may also set other options, such as font.
xyplot(lat ~ long , data = quakes,
main="This is a very long text This is a very long text ")
My way if lost in lattice:
Copy the output you to a text file, and keep it on your disk. Whenever you want
to set a graphics options, search that file for something that comes close, and
use the above get/set.
Don't forget to update the file on lattice updates, these settings change.
Use show.settings() helps sometimes, but it's not complete.
More information about the R-help