jokergoo / EnrichedHeatmap

make enriched heatmap which visualizes the enrichment of genomic signals to specific target regions.
http://jokergoo.github.io/EnrichedHeatmap/
Other
186 stars 25 forks source link

Question: Setting `lwd` for all heatmaps #49

Closed dktanwar closed 4 years ago

dktanwar commented 4 years ago

Is it possible to set lwd to everything on an EnrichedHeatmap?

I tried

border_gp = gpar(col = "black", lwd = 0.4) I would like to set it for top_annotation, column_title border, and x-axis.

jokergoo commented 4 years ago

There is no parameter for globally controlling the graphic parameters, but in grid, all the children viewports inherit the graphic parameters from parent viewport, so you do like this:

grid.newpage()
pushViewport(viewport(gp = gpar(lwd = 0.1)))
draw(enrichedHeatmap(...), newpage = FALSE)
popViewport()
dktanwar commented 4 years ago

Amazing!

Thank you so much!