[R] Scatterplot - Overlap Frequency

Mestat mestat at pop.com.br
Thu Aug 12 22:19:57 CEST 2010


Hi listers...
I am working o a scatterplot where I would like to plot the variables
according with another frequency variable.
Another friend here proposed this code...
x <- rnorm(10)
y <- rnorm(10)
ind <- c(1,0,1,0,1,0,1,1,0,0)
plot(x, y, col = ind + 1, pch = 16)  # 1 is black, 2 is red 

But in my case I would like to identify with different colors according with
a frequency variable.
x <- rnorm(10)
y <- rnorm(10)
ind <- c(3,0,1,0,3,0,2,2,0,0)

I made some research and I would like to do something like the function
HEXBIN does:
source("http://bioconductor.org/biocLite.R")
biocLite("hexbin")
library(hexbin)
x <- rnorm(1000)
y <- rnorm(1000)
bin<-hexbin(x, y, xbins=50)
plot(bin, main="Hexagonal Binning")

But in my case I have another variable with the frequency and not high
density frequency according the two plotted variables...
Any suggestions, thanks...
Marcio

-- 
View this message in context: http://r.789695.n4.nabble.com/Scatterplot-Overlap-Frequency-tp2323322p2323322.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list