adding row label instead of row names

Thank you, Seidel. Yes, I want to avoid the row names, and I did that earlier: show_rownames = FALSE, which worked well. I also removed the dendrogram along the y-axis. The aim was to put the label “participants” into the position where the rownames were before. I played around with the grid.text function but I couldn’t make it work. I end up getting an error message: non-numeric argument to binary operator

Maybe easier to show, here is my codeline:
pheatmap(data3, color=colorRampPalette(c(“white”, “yellow”, “red”))(50), legend_breaks = c(0, 500, 1000, 1500, max(data3)),
main = “”, legend_labels = c(“0”, “500”, “1000”, “1500”, “sqrt counts\n”),
show_rownames = F, cluster_rows = FALSE)
with: + grid.text(“participants”, x=0.9, y=0.5, rot=270)
I get the error message
I don’t know how to post an image of my heatmap but maybe that’s not necessary.

Read more here: Source link