highlight specific gene name in pheatmap

1.2k Views Asked by At

I would like to ask if there is a possibility to highlight some gene names(row names) in the heatmap package? I want to highlight the row names "I", "H", and "G" in a different color(red color) keep the rest as it is. Here is my code

set.seed(22)
li.A <- matrix(rnorm(50), nrow = 10)
rownames(li.A) <- LETTERS[1:10]
colnames(li.A) <- paste0("S_", ncol = 1:5)
library(pheatmap)
pheatmap(li.A)

Thank you so much!

1

There are 1 best solutions below

0
On

This page has the answer https://github.com/raivokolde/pheatmap/issues/48 Best, Amare