Help me with Heatmap
2
0
Entering edit mode
8 weeks ago
vmpsb • 0

Hi everyone, I'm a beginner student who is approaching bioinformatics for the first time and I have some difficulties with DESeq 2.

I need to create a heatmap with the top 36 genes, these are the instructions I was given but I couldn't understand:

  • For the heatmap you need to transform the output of the DESeq() function;
  • I only display the top 36 genes, otherwise the heatmap is unreadable;

I should use this formula but I don't understand how to display top genes in the heatmap:

mat <- counts("#OUTPUT OF DESeq()", normalized = T)[rownames(top_36),]
mat.z <- t(apply(mat, 1, scale))
colnames(mat.z) <- coldata$sample
df <- as.data.frame(colData("#OUTPUT OF DESeq()")[,c("hour","strain")])
  • Heatmap with pheatmap()

I would be very grateful if anyone could help me, thanks in advance.

RNA-seq R DESeq2 • 348 views
ADD COMMENT
2
Entering edit mode
8 weeks ago
  1. you have to say what question you are actually asking. There are few different designs that would address different questions.
  2. work through the vignette. Then find another tutorial, and work through that before trying with your own data.
ADD COMMENT
0
Entering edit mode
8 weeks ago
MolGeek ▴ 80

Hello!

So, what is the correct design ?

You will have to ask yourself, what do you want to compare? WT vs mut? If so it will be strain. 20 vs 25? It will be hour. WT at 20 vs mut at 20? It will be strain + hour.

Then:

dds <- DESeq(ddsTxi)

# Then check the contrast option from results about the design of your preference. For example if you want WT vs mut. 
res <- results(dds, contrast=c("strain","mut","WT"))

After the results, you can select the top15 upregulated genes and 15 downregulated genes based on the log2foldchange column and try to make the heatmap.

A comment to add. Do not erase or change the question, just add a comment! There exist people who might have the same question as you and as such those questions are beneficial!

ADD COMMENT

Login before adding your answer.

Traffic: 1147 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