Making heatmap for pseudotime with clusters annotation
0
0
Entering edit mode
6 weeks ago

Hello,

I'm currently trying to do heatmap of selected gene expression through my pseudotime.

What I have done currently , is to first create a dataframe with my cells and gene expression value. Then I have order my cells based on my pseudotime.

Now I can plot my heatmap, but the problem is that I don't have the clusters of reference for my cells. I don't know how I can integrate it into my heatmap.

Here is what I want to do :

(Figures F-G-H)

Thank you very much

clusters pseudotime heatmap • 306 views
0
Entering edit mode

Are you doing this in Python or R? You also may want to include a sample of your code so we know what you've done so far.

0
Entering edit mode

Sorry i was not precise . It's on R . i'm actually trying to plot this heatmap

In that heatmap , the cells have been ordered according to heir pseudotime . Actually what i have done , is first extrating my matrix ( metadata who came from seurat object )

here , each cells have been ordered according to their pseudotime ( first row ) .

And here is my expression matrix

once again the cells in rownames , have been ordered according to the pseudotime. So what i want to do is to compute a heatmap with my expression matrix, but also include in that heatmap the clusters of origin of my cells like what they have done in the figure .

0
Entering edit mode

Look into ComplexHeatmap - that's probably what that paper has used. You'll need to create a Heatmap() object with the expression data and use the clusters of origin as a rowAnnotation.

Learning how to do this will be a good exercise for you. See examples here: https://jokergoo.github.io/ComplexHeatmap-reference/book/heatmap-annotations.html#block-annotation