[R] Help labeling Panels

From: MTHarden <mitch.harden_at_gmail.com>
Date: Sun, 27 Mar 2011 09:17:30 -0700 (PDT)


Hi,

I'm new. I tried to search out this answer but I suspect I was using the wrong terms, or simply not understanding some of the answers. Anyway here is my question:

I want to have a 2x2 panel figure with 4 line graphs all in the same scale. Actually I have that. The thing I seem to be lacking is a way to Label each panel with a letter. I want it to look something like this:

http://www.nature.com/npp/journal/v31/n9/images/1301015f3.gif

I am using linux and I'm not even entirely sure if I've done this in a best practices sort of way but here is the code that I've entered so far to make my figure:

library(sciplot)
postscript('PreferenceGraph2x2.eps')
par(mfrow = c(2,2), pin=c(6.45669292,6.45669292), pty="m") lineplot.CI(Week, Pref, group = Drug, data=SM.long, xlab = "Week", ylab ="Proportion Sucrose of Total Fluids", x.leg =1, y.leg=.91, leg.lab= c("Salvia","Control"),col =c("red","darkgreen"),ylim=c(0.48,.95), main =
"Preference of Stressed Males")

lineplot.CI(Week, Pref, group = Drug, data=SF.long, xlab = "Week", ylab ="Proportion Sucrose of Total Fluids", x.leg =1, y.leg=.60, leg.lab= c("Salvia","Control"),col =c("red","darkgreen"),ylim=c(0.48,.95), main =
"Preference of Stressed Females")

lineplot.CI(Week, Pref, group = Drug, data=NSM.long, xlab = "Week", ylab ="Proportion Sucrose of Total Fluids", x.leg =1, y.leg=.64, leg.lab= c("Salvia","Control"),col =c("red","darkgreen"),ylim=c(0.48,.95), main =
"Preference of Non-Stressed Males")

lineplot.CI(Week, Pref, group = Drug, data=NSF.long, xlab = "Week", ylab ="Proportion Sucrose of Total Fluids", x.leg =1, y.leg=.64, leg.lab= c("Salvia","Control"),col =c("red","darkgreen"),ylim=c(0.48,.95), main =
"Preference of Non-Stressed Females")

dev.off()

Thanks in advanced for any help you might give!

--
View this message in context: http://r.789695.n4.nabble.com/Help-labeling-Panels-tp3409528p3409528.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help_at_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.
Received on Sun 27 Mar 2011 - 17:03:16 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Sun 27 Mar 2011 - 17:20:25 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive