This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Explanation of dimension differences between bam files (BWA aln and BWA mem)

Hello everyone,

I want to compare the output .bam files generated by two different algorithms: BWA aln and mem, in order to replace the old code (aln) with the new one (mem)

For aln alignment I ran the following command:

bwa aln -o 1 -n 0.01 -l 200 -e 12 -d 12 -t 30 'ref.fa' 'pair_1.fastq' 'pair_2.fastq.gz' | samtools sort -@30 -o out.aln.bam 

For mem:

bwa mem -t 30 -M 'ref.fa' 'pair_1.fastq'  'pair_2.fastq' | samtools sort -@30 -o out.mem.bam -

The dimension of out.aln.bam resulted in 24689 MB. The dimension of out.mem.bam resulted in 31069 MB.

Considering that the input fastq files are the same, how can I explain this huge difference in dimensions? Is it due to options in aln?

Thanks in advice

r rna-seq bwa gene alignment

Rather than comparing the file sizes, you should compare the alignment statistics.

0 answers

No answers yet.

Log in to answer this question.