This is a test version of Biostars. For the public version, visit https://www.biostars.org.
difference between BWA mem, sampe and bwasw

Hi,

I was wondering what is the difference between BWA mem, sampe and bwasw options for aligning paired-end data. I have PE data with the read length ~100 bp before trimming for whole exome analysis. I am aligning them using the following command:

bwa mem -t 4 -M L001_R1_001_trimmed.fq L001_R2_001_trimmed.fq > L001.sam

I am wondering if

  1. The above command is OK for paired-end data?
  2. BWA mem is the best option for this?

Thanks,
N

bwa paired-end

1 answer

That command won't work because you haven't specified a reference. Otherwise it looks fine for a basic bwa mem alignment operation.

BWA can employ variations of the alignment algorithm, and you can specify which one you want to use by how you invoke bwa. See this question for more information about the specific differences.

bwa samse / sampe are run as the second step in a two-step alignment process. samse works with single-read alignment output, and sampe with paired-end. samse / sampe will take the output of bwa aln and write SAM data from it.

Thanks Dan D,

Actually, there is a reference in my original command; it just got deleted when I cleaned it to remove the full file paths, etc.

Another question: Is BWA sampe preferred over BWA mem for exome analysis (as opposed to WGS)? If I ran BWA aln followed by sampe, will I get roughly same output alignment as BWA mem?

Thanks!

Based on your read length and the general superiority of bwa mem over bwa aln I would choose bwa mem. If you have the spare compute capacity I would recommend running both on a few samples and comparing basic metrics from samtools flagstat. It wouldn't be much additional work.

Log in to answer this question.