Re: [R] Plotting different symbols in R for different values in a vector

2010-06-17 Thread Joris Meys
use the condition and par options, eg : x <- rnorm(10) y <- rnorm(10) A<- x<0 plot(x,y,type="l") points(x[A],y[A],pch=19,col="red") points(x[!A],y[!A],pch=21,col="blue",bg="green",lwd=2,cex=4) cheers Joris On Thu, Jun 17, 2010 at 3:55 PM, clips10 wrote: > > I have some point locations I want to

Re: [R] Plotting different symbols in R for different values in a vector

2010-06-17 Thread Sarah Goslee
Take a look at ?par - particularly the options for pch and col. Sarah On Thu, Jun 17, 2010 at 9:55 AM, clips10 wrote: > > I have some point locations I want to add to a plot and have the command > > pts1<-as.points(Xcoordinate,Ycoordinate) > > then > > > plot(poly1,type="l",lwd=1) > > what I wan

[R] Plotting different symbols in R for different values in a vector

2010-06-17 Thread clips10
I have some point locations I want to add to a plot and have the command pts1<-as.points(Xcoordinate,Ycoordinate) then plot(poly1,type="l",lwd=1) what I want to do is add the locations onto the plot. I can do this using the points command but I have another vector in my data frame with the x