[R] Problems with combining plots

johnhj jharris at web.de
Sun Mar 22 15:50:42 CET 2009


Hii,

I will combine some plots. Like this example here
http://www.statmethods.net/advgraphs/layout.html I tired to do it for 2
plots but without success.

Here is my code:

test<-read.table(file="D:/file.txt")
space<-read.table(file="D:/space.txt")

space$gruppe <- 502*rep(1:6, each=7)
x<- c(test$V1)
y<- c(test$V2)

par(mfrow=c(1,1)) 

png(filename = "D:/example.png", width = 640, height = 480, pointsize = 12,
bg = "white",  res = NA)

boxplot(V2 ~ gruppe , data = space , col = "lightgray",boxwex=0.2)
plot(panel.first=grid(ny=NULL,nx=NULL),x,y, xlab = "Zeit(sec)", ylab
="Datenrate(MBit(sec))",ylim=c(0,40), col ="purple", type ="l", main
="combined plots",lwd=2)

dev.off()


What is the mistake in my code ? 


-- 
View this message in context: http://www.nabble.com/Problems-with-combining-plots-tp22646692p22646692.html
Sent from the R help mailing list archive at Nabble.com.




More information about the R-help mailing list