tags:

views:

129

answers:

1

Hello SOers, I'm sure this is an easy problem, but my google / help foo has failed me, so it's up to you.

I have an R script that generates several plots, and I want to view all the plots on screen at once (in seperate windows), but I can't work out how to open multiple graphics windows. I'm using ggplot2, but I feel this is a more basic problem, so I'm just using base grapics for this simple example

x<-c(1:10)
y<-sin(x)
z<-cos(x)
dev.new()
plot(y=y,x=x)
dev.off()
dev.new()
plot(x=x,y=z) 

But this doesn't work. I'm on Windows if this matters (Windows + Eclipse + StatEt)

+5  A: 

This works fine if you remove the line with dev.off().

Shane
Perfect, I also just found the help for dev.list and dev.set which should do everything I want. Ta.
PaulHurleyuk