On Wed, Sep 30, 2009 at 6:54 AM, Andrewjohnclose <a.j.cl...@ncl.ac.uk> wrote: > > Hi, > > I'm having trouble matching the symbols/color of the key to match those > specifiec in the plot. > > Here is the code I used: > > > xyplot(GCR+GCT ~ FRAC, data=RWF, type=c("g","p"),cex=1.2,pch=c(22,21), > xlab=expression(italic("f")),ylab=expression(italic("S")), > key=list(points=list(pch=c(22,21),cex=1.2), > text=list(c("Targeted Deletion","Random Deletion")))) > > I'm, sorry if this is an apparently easy/obvious mistake on my part.
(For complicated reasons, ) The easiest way to to do this is with something like xyplot(GCR+GCT ~ FRAC, data=RWF, type=c("g","p"), xlab=expression(italic("f")),ylab=expression(italic("S")), par.settings = simpleTheme(cex=1.2,pch=c(22,21)), auto.key = list(text=c("Targeted Deletion","Random Deletion"))) -Deepayan ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.