x1 <- 1:9
y1 <- x1
x2 <- x1
y2 <- 9-x1
plot(c(0, 9), c(0, 9), type="n")
points(x1, y1, col=1, pch=1)
points(x2, y2, col=2, pch=2)
Is this what you want?
Spencer Graves
Vasudevan, Geetha wrote:
Hello,
I am trying to do a scatter plot of x1,y1 and x2,y2 in the same graphics window with diff col/pch
Either
n1 <- length(x1)
n2 <- length(x2)
plot(c(x1,x2),c(y1,y2),col=rep(c(1,2),c(n1,n2)), pch=rep(c(1,2),c(n1,n2))
OR
plot(x1,y1,xlim=range(c(x1,x2)),ylim=range(c(y1,y2)),col=1,pch=1)
points(x2,y2,col=2,pch=2)
will work.
Ben Bolker
On Wed, 26 Mar 2003, Vasudevan, Geetha wrote:
> Hello,
n Behalf Of
> Vasudevan, Geetha
> Sent: den 26 mars 2003 19:35
> To: [EMAIL PROTECTED]
> Subject: [R] 2 scatter plots in the same graphic window
>
>
> Hello,
>
> I am trying to do a scatter plot of x1,y1 and x2,y2 in the
> same graphics window with diff co
Hello,
I am trying to do a scatter plot of x1,y1 and x2,y2 in the same graphics window with
diff col/pch values. i cannot get it to do them in the same window.
what is the cmd to do this? thanks.
__
[EMAIL PROTECTED] mailing list
https://www.stat.mat