I have almost done with my heatmap but I cannot figure out how to modify the command in order to see the label. Please, see below:
## Import dataset data <- read.table("Genes_with_function.txt", header = TRUE, sep = "\t", dec = ".") mat_data <- data.matrix(data[,2:ncol(data)]) # transform to Z-scale mat <- t(scale(t(data.matrix(mat_data)))) # set colour myCol <- colorRampPalette(c("#f03b20", "#fff7bc", "#2c7fb8"))(100) myBreaks <- seq(-2, 3, length.out=100) # For ID ID <- read.table("ID.txt", header = TRUE, sep = "\t", dec = ".") ### a new .txt file with only the ID of the genes # Do the plot hmap <- pheatmap(mat, cluster_rows = TRUE, cluster_cols = TRUE, scale = 'none', breaks = myBreaks, col = myCol, show_colnames = TRUE, labels_row = ID$ID)
Then I get this heatmap: https://ibb.co/nzMMy5t
As you can see the names of the genes (TRINITY blahblah) is imposible to see. Is there any way of specify that?
By the way the ID file looks like this:
Thank you in advance