Closed jokergoo closed 6 years ago
library(EnrichedHeatmap)
load(system.file("extdata", "chr21_test_data.RData", package = "EnrichedHeatmap"))
tss = promoters(genes, upstream = 0, downstream = 1)
mat1 = normalizeToMatrix(H3K4me3, tss, value_column = "coverage",
extend = 5000, mean_mode = "w0", w = 50)
ht1 = EnrichedHeatmap(mat1, col = colorRamp2(quantile(mat1, c(0, 0.99)), c("white", "red")),
column_title = "continuous")
rule = list("high" = c(40, Inf),
"intermediate" = c(20, 40),
"low" = c(1e-6, 20))
mat2 = discretize(mat1, rule)
ht2 = EnrichedHeatmap(mat2, col = c("high" = "red", "intermediate" = "blue", "low" = "green"),
column_title = "discrete")
ht1 + ht2
Assume a normalized matrix has both positive value and negative value, we only want to see the enrichment of windows/regions show significant positive values and negative values and we are only interested in the direction of the values while not the value itself:
Or something like: