Question: Merge The Sam Files For Dexseq
0
gravatar for camelbbs
5.8 years ago by
camelbbs650
China
camelbbs650 wrote:

I have RNAseq data for one sample, with two technical replicates. As I know, I need to merge them to get the gene or exon counts.

Now I get the sam files from the two techinical replicates, can I merge the sam files as: cat 1.sam 2.sam > merged.sam and then sort -k1,1 -k2,2 merged.sam?

I want to use the merged sam file for dexseq_counts.py. My sam files don't have header.. Anyone has an idea about that? Thanks..

sam • 3.2k views
ADD COMMENTlink modified 5.8 years ago by venkateshr89690 • written 5.8 years ago by camelbbs650
5
gravatar for venkateshr89
5.8 years ago by
venkateshr89690
United States
venkateshr89690 wrote:

You can just merge the SAM files by "cat" function. Btw I don't understand why you have sam files. It will just fill up your hard drive. Downstream analysis in DEXSeq can accept BAM files. Also I wonder why your sam files did not have headers. Please try using IGV browser to see if your alignment looks fine before DEXSeq. Since you will be wasting lot of time if the counts generated by DEXSeq are wrong.

ADD COMMENTlink written 5.8 years ago by venkateshr89690

I need to count the reads on exons by dexseq_counts.py, that need sam files, right?

ADD REPLYlink modified 5.8 years ago • written 5.8 years ago by camelbbs650
2

yes, If you are using DEXSeq_count.py to generate the count files. I always use HTSeq_count.py. I don't see a point why you should not DEXSeq_count.py. You are in right path. Good luck

ADD REPLYlink written 5.8 years ago by venkateshr89690
1
gravatar for Devon Ryan
5.8 years ago by
Devon Ryan88k
Freiburg, Germany
Devon Ryan88k wrote:

If they don't have headers, then just concatenating them will work fine. I wonder why they don't have headers though, that's odd. The sort should name sort them correctly. BTW, with many mappers, you can just supply a list of technical replicate files separated by a comma and the mapper will just output a single file with all of the reads (just to save you a step).

ADD COMMENTlink written 5.8 years ago by Devon Ryan88k

My technical replicates are single-end and paired-end, so I think I can't merge them before I map them.

ADD REPLYlink written 5.8 years ago by camelbbs650
1

Ah, in that case yes.

ADD REPLYlink written 5.8 years ago by Devon Ryan88k
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: 1875 users visited in the last hour