HI All,

i need to call the tree map function in R to display my multiple disks usage, 
using ‘portfolio' library. I need furthermore to generate multiple page each 
showing the treemap of each disk. It works fine if use pdf file , but my boss 
wants to save the result into an html file. Any help? I’ve tried with R2HTML 
library without success. The output of map.market is a ‘gTree' object. Any help 
is appreciated.

library(portfolio)
data1 <- read.csv("C:/Users/Administrator/Desktop/prova_data1.txt", sep='\t', 
stringsAsFactors = FALSE)
data2 <- read.csv("C:/Users/Administrator/Desktop/prova_data2.txt", sep='\t', 
stringsAsFactors = FALSE)
data2 <- read.csv("C:/Users/Administrator/Desktop/prova_data3.txt", sep='\t', 
stringsAsFactors = FALSE)
pdf("C:/Users/Administrator/Desktop/treemap.pdf")
map.market(id = data1$Id, area = data1$size, group = data1$Storage, color = 
data1$col, lab=c(TRUE,TRUE), main="Test Map")
map.market(id = data2$Id, area = data2$size, group = data2$Storage, color = 
data2$col, lab=c(TRUE,TRUE), main="Test Map")
map.market(id = data3$Id, area = data3$size, group = data3$Storage, color = 
data3$col, lab=c(TRUE,TRUE), main="Test Map")
dev.off()
______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to