Merge The Sam Files For Dexseq
2
0
Entering edit mode
11.6 years ago
camelbbs ▴ 710

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 • 4.9k views
ADD COMMENT
5
Entering edit mode
11.6 years ago
venks ▴ 740

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 COMMENT
0
Entering edit mode

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

ADD REPLY
2
Entering edit mode

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 REPLY
1
Entering edit mode
11.6 years ago

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 COMMENT
0
Entering edit mode

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

ADD REPLY
1
Entering edit mode

Ah, in that case yes.

ADD REPLY

Login before adding your answer.

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