Question: From DESeq2 normalized counts to heatmap in R
0
gravatar for dnzkursun
12 months ago by
dnzkursun10
dnzkursun10 wrote:

Hi, I have normalized counts data and DESeq2 result file (including log2FC and Padj values) of each sample. And I want to generate a heatmap of significantly differentially expressed genes (FDR<0.05; log2FC>2) in R studio. However, I could not be sure how to filter the significantly expressed genes from only these files and unfortunately, I do not have the chance to re-run the DEseq2 analysis. Can anyone give me some suggestions on data filtering and scaling options to generate heatmap?

From the DESeq2 manual, I read that VST or rlog transformation can be done before heatmap, but since I already have the normalized count data I guess converting them into Z-score can be another option? Any suggestion will be appreciated.

Best,

Deniz

heatmap rna-seq deseq2 • 1.8k views
ADD COMMENTlink modified 12 months ago by i.sudbery9.7k • written 12 months ago by dnzkursun10
2
gravatar for i.sudbery
12 months ago by
i.sudbery9.7k
Sheffield, UK
i.sudbery9.7k wrote:

First you definitely want to rlog or VST transform your count data, even if it is already normalized, so that should be your first step.

Your both your DESeq results table and your counts matrix should have rownames corresponding to the genes they represent. The second step is to filter the DESeq results table to grab only those rows with FDR<0.05 and abs(log2FC) > 2, and extract the rownames from the resulting table as your list of DE gene names.

Finally, use this list to subset the rlog/vst transformed count data to get the matrix that you can turn into a heatmap with heatmap.2 or ComplexHeatmap.

ADD COMMENTlink written 12 months ago by i.sudbery9.7k

Thank you very much for providing all the necessary information.

ADD REPLYlink written 12 months ago by dnzkursun10
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1257 users visited in the last hour