jokergoo/EnrichedHeatmap

enriched heatmap cut rows

yamihn opened this issue · 0 comments

hi, I'm trying to plot a heatmap with 2388 rows that I previously plot fine.
Now, it seems that enriched heatmaps cuts half of the rows.
I am not able to see what is happening.
There is the code:

u= rbind(mat_kod8, mat_wtd8)
base_mean = rowMeans(u)
row_split = rep("KO d8", nrow(u))
row_split[(nrow(u)/2+1):nrow(u)] = "WT d8"
lgd = Legend(at = c("KO d8", "WT d8"), title = "Sample", 
             type = "lines", legend_gp = gpar(col = 2:3))
ht_list = EnrichedHeatmap(u, name = "fragment", column_title = "peaks",
                          row_split= row_split, use_raster= F, 
                          top_annotation = HeatmapAnnotation(
                            enriched = anno_enriched(gpar(col= 2:3),
                                                     #ylim = c(0, 0.4),
                                                     axis_param = list(
                                                       # at = c(0, 5, 10),
                                                       #labels = c("zero", "five", "ten"),
                                                       side = "left",
                                                       facing = "outside"
                                                     )))) +
  Heatmap(base_mean, name = "Mean", 
          top_annotation = HeatmapAnnotation(summary = anno_summary(gp = gpar(fill = 2:6), 
                                                                    height = unit(2.5, "cm"))),
          width = unit(10, "mm"))

ht_list = rowAnnotation(block = anno_block(gp = gpar(fill = 2:3, col = NA)), 
                        width = unit(3, "mm")) + ht_list
b=draw(ht_list, annotation_legend_list =list(lgd))