I am drawing a heatmap with pheatmap package in R. I would like to show a certain property of two datasets and show two heatmaps next to each other. However, the order of the columns/rows in both heatmaps is slightly different. I understand that the order in which the columns/rows are organized has it's function in heatmap.
However, the two sample types I would like to change the order of, are next to another and this shouldn't disturb the whole idea of clustering. Is it possible to change the order of samples on a heatmap in pheatmap package ?
Please look at the example below:
I would like to have control in the bottom-right, and f4 in the middle. That would make this heatmap consistent with the other one I generated.