[R] Publication-ready figures in R?

S Ellison S.Ellison at LGCGroup.com
Tue Jan 28 17:39:57 CET 2014

> > labelling of figure parts with a, b, c etc. in the top left corner
> > that should be easy to achieve in R.

It is; use par("usr") to get the corners and text() to place labels inside the plot region, as in
text(par("usr")[1], par("usr")[4], "a)", cex=1.5, adj=c(-0.2,1.2))

or something like
mtext("a)", outer=T, line=-1.5, cex=1.5, adj=0.02)
for labels in a corner of the device region.

But it Would Be Nice If xy.coords understood "topleft" etc. so that text() could pass that through. One for the wish list one day, perhaps, though text() would also have to use adj intelligently by default to make life simple when it saw character x.

S Ellison

This email and any attachments are confidential. Any use...{{dropped:8}}

More information about the R-help mailing list