Re: [R] more outrageous plotting

2007-11-23 Thread S Ellison
Within the base package collection, see ?colorRamp and ?colorRampPalette Then or.to.blue<-colorRampPalette(c("orange","green","blue")) #green included to avoid muddy blues plot(df$X, df$Y,type="n") text(df$X, df$Y, labels=df$Z, col=or.to.blue(length(df$Z))[rank(df$Z)]) You don't need to order by

Re: [R] more outrageous plotting

2007-11-23 Thread Jim Lemon
Juan Pablo Fededa wrote: > Dear Contributors: > > I have the next matrix: > > "X" "Y" "Z" > > 1 2 526 > 2 5 723 > 310 110 > 4 7 1110 > 5 9 34 > 6 8 778 > 7 1 614 > 8 4 876 > 9 6 249 > 10 3 14 > > I want

Re: [R] more outrageous plotting

2007-11-22 Thread hadley wickham
Hi Juan, Assuming that your data frame is named df, something like the following should work: library(ggplot) qplot(X, Y, data = df, colour = Z, label = Z, geom = "text") + scale_colour_continuous(low="orange", high = "blue") You can find out more about ggplot2 at http://had.co.nz/ggplot2. Had

Re: [R] more outrageous plotting

2007-11-22 Thread Moshe Olshansky
One way to do this may be to create the right image and show it. I have never user R for image processing so I can not provide any details, but I would have done the following: Create a 100x100 (or 1000x1000) white image. Then (assuming that it is a 100x1000 image), for each pair of your (x,y) you

[R] more outrageous plotting

2007-11-22 Thread Juan Pablo Fededa
Dear Contributors: I have the next matrix: "X" "Y" "Z" 1 2 526 2 5 723 310 110 4 7 1110 5 9 34 6 8 778 7 1 614 8 4 876 9 6 249 10 3 14 I want to order the matrix from bigest Z (1110) to lower Z (14). The