[R] side by side plots

From: <hpbenton_at_scripps.edu>
Date: Mon, 7 Jan 2008 12:59:34 -0800 (PST)

Hello everyone,

I have an overlay plot it's nice but you can't see all the data. I would like to know if there is a way to get a plot that gives a side by side plot so that each plot would be next to each other. The two plots have the same data are of different species. At the moment this is the code I'm using:

exp<-cbind(abs(round(rnorm(10),2)*10), seq(100, 200, by=10)) ref<-cbind(abs(round(rnorm(10),2)*10), seq(100, 200, by=10))

plot(ref, ylab="Intensity", xlab="wavelength", type="h") points(exp, type="h", col="red")

This is working in a script and I would like to have a single pdf/png file for the user with this plot, rather than asking the user to manually compare them.

Any ideas on how I would do this?



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 Mon 07 Jan 2008 - 21:04:27 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 Tue 08 Jan 2008 - 00:30:05 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