I try this:
testd <- data.frame(ID=1:10,cl=sample(1:10,100,replace=TRUE),x=runif(100),y=2*runif(100))
testd$ID <- factor(testd$ID)
testd$cl <- factor(testd$cl)
levels(testd$cl)
rPlot(y~x, data = testd, color = 'cl',
tooltip = "#!function(item){ return 'cl: ' + item.cl + ' id: ' + item.ID }!#",
type = 'point', ylim=c(-0.5,1.5))
But I get a legend with only 4 levels (2,4,6,8), while I have 10 levels in cl Why? Also, I do not get to control the axes limits.
Any help appreciated,
Thanks