[R] Multiple colors in plots/lookup function
David Forrest
drf5n at mug.sys.virginia.edu
Thu Oct 17 06:04:17 CEST 2002
Hello,
I'd like to do something like:
n<-100
zz<-cbind(rnorm(n),rnorm(n),floor(runif(n)*3+1))
colors<-c("red","green","blue")
plot(zz,col=colors(zz[3]))
and have a matrix of scatterplots colored by class. The above does not
work, of course, but I'm not sure exactly what function I'm looking for.
Thank you for your time,
Dave,
--
Dave Forrest (434)924-3954w(111B) (804)642-0662h (804)695-2026p
drf5n at virginia.edu http://mug.sys.virginia.edu/~drf5n/
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list