How to change color of rownames display in pheatmap


The row name labels of my heatmap are genes. The default color for the column names and row names are black, however, I would like to change some gene names to different colors (for example, red for up-regulated genes and blue for down-regulated genes, similar to volcano plot)

It seems that there is no function in pheatmap can change this setting. The most possible one is labels_row to custom labeled row names. Does anyone know how to custom row name color?

pheatmap(test, cellwidth=30, , cellheight = 10, angle_col = 45, annotation_col = df, labels_row = ???)




Source link