Hi all,
This might not be a completely bioinformatical question. But I am plotting a heatmap with ComplexHeatmap
with rows as genes and columns as samples. Since I have too many genes plotted, I decided to use anno_mark
to show only those that I am interested in. All was working well, until I realized that the position of the labels
will change when I tweak with the dimensions of the heatmap. Furthermore, the change in position of the labels is not proportional to the heatmap itself, causing my anno_marks
to be at different row positions under varying heatmap heights.
Just wondering if anyone has met this problem before and how they come about stablizing this. Thanks.
This is a follow up on the thread just incase anyone else has stumbled upon this problem. The
anno_mark
positioning seems to accurate once the plot is saved toJPG
instead of visualizing it on the console. Simply usejpeg()
before plotting followed bydev.off()
after the plot should work. Changing the dimensions does not seem to affect theanno_mark
positioning.