row.mdat <- matrix(c("FALSE","FALSE",
"TRUE","TRUE",
"FALSE","FALSE",
"TRUE","FALSE",
"FALSE","TRUE"
),
nrow = 5, ncol = 2, byrow = TRUE,
dimnames = list(
c("probe1", "probe2","probe3","probe4","probe5"),
c("duplicated", "Enhancer region")))
dat <- matrix(c(0.3,0.2,0.3,1,1,0.1,1,1,0, 0.8,1,0.7,0.7,0.3,1),
nrow = 5, ncol = 3, byrow = TRUE,
dimnames = list(
c("probe1", "probe2","probe3","probe4","probe5"),
c("TCGA-DU-6410",
"TCGA-DU-A5TS",
"TCGA-HT-7688")))
mdat <- data.frame(patient=c("TCGA-DU-6410","TCGA-DU-A5TS","TCGA-HT-7688"),
Sex=c("Male","Female","Male"),
COCCluster=c("coc1","coc1","coc1"),
IDHtype=c("IDHwt","IDHMut-cod","IDHMut-noncod"))
TCGAvisualize_Heatmap(dat,
col.metadata = mdat,
row.metadata = row.mdat,
row.colors = list(duplicated = c("FALSE" = "pink",
"TRUE"="green"),
"Enhancer region" = c("FALSE" = "purple",
"TRUE"="grey")),
col.colors = list(Sex = c("Male" = "blue", "Female"="red"),
COCCluster=c("coc1"="grey"),
IDHtype=c("IDHwt"="cyan",
"IDHMut-cod"="tomato"
,"IDHMut-noncod"="gold")),
type = "methylation",
show_row_names=TRUE)
if (!(is.null(dev.list()["RStudioGD"]))){dev.off()}
Run the code above in your browser using DataLab