how merge the gene expression value of two sample
1
0
Entering edit mode
5.6 years ago
lkianmehr ▴ 100

Hello,

I need your help to resolve this question, maybe is easy but I am new about it. I would be appreciated if give me please any idea about that.

actually, I have 8 sample (count file from HTSeq-count of RNA-seq data, with this order: D1_1, D1_2, D3_1, D3_2, R1_1, R1_2, R3_1, R3_2) and make them into 4 group (2 sample in each one). Now I am going to calculate the proportion of gene expression for each group. I have log scaled and normalized them, but I want to merge the ratio of gene expression of each 2 sample together (for ex D1_1 and D1_2) to do the next analysis. could you give me any advice to do that?

my dataset is like this:

                        D1_1                D1_2                D3_1                D3_2    
ENSMUSG00000000001.4    1.39484378430357    2.46452589579488    2.15638312017686    1.39484378430357    
ENSMUSG00000000003.15   0.211843606133756   0.360646924628625   0.307483505135223   0.211843606133756

but I want to have D1 (D1_1 and D1_2) versus D3 (D3_1 and D3_2). I need to merge or don't know should be gotten average or what else?

thanks in advance

DESeq RNA-Seq gene-expression • 2.3k views
ADD COMMENT
0
Entering edit mode

Good description of the data and problem. Please post some example data and expected output, if possible

ADD REPLY
0
Entering edit mode

Is there a reason you are not using an established package like deseq2 to do this analysis?

ADD REPLY
0
Entering edit mode

No, I did differential Gene expression analysis by DESeq2 but now I want to just compare gene type of each group on based of gene expression value, not DGE analysis, you mean I can do this work by DESeq2, if so, how?

ADD REPLY
0
Entering edit mode

What do you mean by compare gene type? Is there any reason you can't use the DESeq2 logFoldChange values to compare between the groups?

ADD REPLY
0
Entering edit mode

because I want to just calculate the proportion of gene type (Protein coding, miRNA, MiscRNA and etc) on each group, not DGE!

ADD REPLY
0
Entering edit mode

Still not sure I understand completely. Can you maybe post an example of the output you want/expect?

ADD REPLY
0
Entering edit mode

yes, I expect to have a result like this:

gene    D1  D3  R1  R3  type    
0610005C13Rik   3.26    4.09    3.14    1.03    antisense_RNA   
0610009B22Rik   0.57    0.46    0.91    2.21    protein_coding  
0610009E02Rik   0.77    0.42    0.68    1.31    processed_transcript    
0610009L18Rik   0.58    0.56    4   18.07   bidirectional_promoter_lncRNA
ADD REPLY
0
Entering edit mode

So you want to merge (e.g. D1_1 and D1_2 to get just D1, in the example you provide it does not seem to be addition/average) and then annotate each gene row?

ADD REPLY
0
Entering edit mode

No, just to know can I average them to compare them to others as one sample (D1) or not?

ADD REPLY
2
Entering edit mode

Comparing groups of samples is really best done by something like boxplots, as they give a better indication of the variation within each group. However, with only two samples in each group, boxplots aren't an option, so yes, I suppose taking the average is as good an option as any. I would do it with a grain of salt though, and show the actual sample counts/fold changes in any figures you plan to make.

ADD REPLY
2
Entering edit mode
5.6 years ago
h.mon 35k

Are the D1_1 and D1_2 technical replicates? If so, you can use the function collapseReplicates() from DESeq2, this would sum up the counts. Then you can follow up with your regular analysis.

ADD COMMENT
0
Entering edit mode

Oh yeah, completely forgot about this - it is a good option as well.

ADD REPLY
0
Entering edit mode

yes, they are technical replicates. thanks

ADD REPLY
0
Entering edit mode

Sorry, I need your help to write this command correctly, because I am very new with R and DESeq2, I have written this command and faced with this problem could you please correct command it would be needed?

gr <- factor(c(rep("D1", 2), rep("D3", 2)))
colData <- data.frame(group=gr, type="paired-end")
cds <- DESeqDataSetFromMatrix(cn3, colData, design= ~group)
cds <- DESeq(cds)
cnt <- log2(1+counts(cds, normalized=T))
cntColl <- collapseReplicates(cnt, gr, renameCols = TRUE)

Error in (function (classes, fdef, mtable)  :
  unable to find an inherited method for function ‘assay’ for signature ‘"matrix", "missing"’
ADD REPLY

Login before adding your answer.

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