This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Bwa - Bwasw Option - What'S The Output?

I'm trying to give the user of my program the option to run bwa aln or bwa bwasw.

But from reading the documentation I don't understand what the output from running bwasw is.

Would it give me the same output file format as running bwa aln and then bwa samse?

That's ideally what I'd like so that the rest of the pipeline can run without modification.

Update:

I found this cached version of the documentation. It shows this usage example:

bwa index -a bwtsw database.fasta    
bwa aln database.fasta short_read.fastq > aln_sa.sai    
bwa samse database.fasta aln_sa.sai short_read.fastq > aln.sam    
bwa sampe database.fasta aln_sa1.sai aln_sa2.sai read1.fq read2.fq > aln.sam    
bwa bwasw database.fasta long_read.fastq > aln.sam

So it looks like the output of bwa bwasw is the sam format, the same as running aln and then samse.

bwa

With the time you wrote the question, probably you could get the results by running bwasw. You would know better.

1 answer

From the manual

Command ‘bwasw’ is designed for long-read alignment

while aln+samse or aln+sampe is for short reads. Both output files in SAM format.

Also

The algorithm behind, BWA-SW, is similar to BWT-SW, but does not guarantee to find all local hits due to the heuristic acceleration. It tends to be faster and more accurate if the resultant alignment is supported by more seeds, and therefore BWA-SW usually performs better on long queries than on short ones.

So, running the same file with these two algorithms must return different results.

Log in to answer this question.