Hi all, I'm new in this field, and I tried to cluster some TCGA cancer patients for further survival analysis. Just as the TCGA nature paper, I used the k-means method to cluster the normalized RNA-seq data. After that, how can I draw a heatmap like this, to cluster the samples, and do the further survival analysis? Is this done by some specific package? I think the heatmap.2 and pheatmap might not be able to draw the heatmap like this.
Well, the first step is going to be determining what genes to include. This will likely involve a hypothesis test (differential expression). After that, heatmap.2, pheatmap, or even ComplexHeatmap packages will allow you to portray the data. Note that it is quite possible that your samples/genes will not cluster as nicely as the figure you give in your post.
I wanna to cluster the cancer patients into 3 or 4 different groups, with obvious different overall survival of each group. I just try to imitate the nature paper as the link:
Ideally, I wanna the heatmap to show the obvious different patient groups, with the highlight of the characteristic genes in each group, just as the four red rectangle in the nature heatmap.
heatmap.2 would be my guess too. they probably scaled/center the data before plotting the image (you can use the scale() function in R on both rows and cols). for the "bars" on the side and on top they could have done by using the hclust() function with the RColorBrewer package to assign a color to each cluster and passing then the data to the heatmap.2() function. I'm not sure about the white lines though.
ADD COMMENT
• link
updated 22 months ago by
Ram
44k
•
written 9.5 years ago by
TriS
★
4.7k
0
Entering edit mode
Thanks TriS. I found this ggplots tutorial might be useful. I'll try to run and have a look.
It would be useful to see how "this" is like without having to search for the paper. Edit your post to provide a link, please.
So sorry that it's my first time to post here. I tried to upload an image of the heatmap, however failed.
Now I've added the link. Please check. Thanks.