How to scale data for scater plotHeatmap function similar to Seurat?
0
1
Entering edit mode
5.1 years ago
TJ ▴ 50

Hi,

I'm looking to use the plotHeatmap function from scater package using a list of differentially expressed genes that have particular column labels for each cell (cluster labels). When I run differential expression using Seurat's standard method (Wilcoxon Rank Sum Test) then run DoHeatmap(), it requires the SeuratObject to undergo ScaleData before being able to call it for creating the heatmap. When I take the same list of differentially expressed genes and plug it into plotHeatmap function in scater with the logcounts values from SingleCellExperiment object, I do not get the same "pattern" as what's generated by Seurat's DoHeatmap function even though input genes and dataset is the same. I suspect it has to do with how I'm scaling (or not scaling) the data. My question is how exactly does Seurat scale data and can I replicate this with scater?

Thank you.

scRNAseq scater Seurat heatmap • 3.7k views
ADD COMMENT
1
Entering edit mode

i think this answers your question regarding how Seurat scales data: https://github.com/satijalab/seurat/issues/1166

Can you apply ScaleData to the data first then plug it into plotHeatmap?

ADD REPLY
1
Entering edit mode

Thank you for finding that! I also just ran into this as well (somehow I missed this before posting): scRNA-seq, SEURAT, NormalizeData, ScaleData, PCA, CCA ... I didn't know how to pull the scaled data directly from Seurat object to plug into plotHeatmap... I will look into this. Thanks again.

ADD REPLY
1
Entering edit mode

Happy to help. Can you please come back when you've found the answer and let us know? You can post and mark your own answer is accepted/correct. It would be of great use to future bioinformaticians!

ADD REPLY
0
Entering edit mode

In case you have not figured it out yet, to get the scaled data, use GetAssayData(object, slot = "scale.data").

ADD REPLY

Login before adding your answer.

Traffic: 1852 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6