search for: colorvar

Displaying 2 results from an estimated 2 matches for "colorvar".

2013 Jan 17
3
Getting discrete colors on plot
...would like them to be Green for good, Yellow for Questionable, and Red for bad. So I tried to do this in GGPLOT; here is my code: id <- c(1,2,3,4,5) x1 <- c(5,2,3,5,1) x2 <- c(4,1,3,5,1) x3 <- c(5,2,3,5,1) x4 <- c(4,3,3,5,1) x5 <- c(3,1,3,5,1) colorvar <- c(3,1,2,3,1) mydata <- data.frame(id,x1,x2,x3,x4,x5,colorvar) head(mydata) # convert to long format require("reshape") mydata_long <- melt(mydata, id=c("id", "colorvar")) head(mydata_long) require("ggplot2") p <- ggplot(data=mydata_long,...
2013 Jun 11
0
a title on the map (function gvisGeoChart package googleVis )
Hi I am using the package googleVis and the function gvisGeoChart Is it possible to put a title on the map ? Here is the call of the function : library(googleVis) G1 <- gvisGeoChart(PaysProjets, locationvar=''Pays'', colorvar=''NbProj'', options=list( region= "world", displayMode="regions", height=347*1.5, width= 556*1.5 )) plot(G1) Thank you -- Michel ARNAUD Chargé de mission auprès du DRH DGDRD-Drh - TA 174/04 Av Agropolis 34398 Montpellier cedex 5 tel : 04.67.61.75.38 fax : 04....