BWA MEM Definition of a Primary Alignment
1
1
Entering edit mode
5.5 years ago

Quick question:

When bwa mem splits a read into a primary and a secondary/supplementary alignment, is the primary always the "left-most" on the query or is it the more confidently mapped alignment?

Thanks.

alignment bwa mem wgs hts • 5.8k views
ADD COMMENT
2
Entering edit mode

Secondary alignments are not the same as supplemental alignments. Secondary alignments are not split reads, they are alternate positions where the read might align.

ADD REPLY
0
Entering edit mode

Thanks for not answering my question. For chimeric reads (i.e for this example true split-reads that for SV informative) the difference between secondary and supplementary is semantic, a secondary alignment would map to another position but be clipped in a manner that is supporting a breakpoint. Some older SV callers ask users if the -M flag was supplied in mapping.

Hence, my question: is the primary alignment considered to be the left-most on the query or the more confidently mapped alignment?

ADD REPLY
0
Entering edit mode

swbarnes2 answered your question regarding secondary alignments, but not supplementary alignments.

For chimeric reads (i.e for this example true split-reads that for SV informative) the difference between secondary and supplementary is semantic, a secondary alignment would map to another position but be clipped in a manner that is supporting a breakpoint.

According to the current SAM specifications, a secondary alignment is an independent alternate alignment of the entire read. A secondary alignment is a split read alignment

Old versions of the SAM specs did not have supp alignments. The -M flag is available in bwa to allow it to misreport supplementary alignments are secondary for backward compatibility with such programs.

bwa can be configured to report secondary alignments for a subset of reads using the -a, but in the general case, it does not use secondary alignments and uses it's own non-standard XA tag to write secondary alignments when the -h flag is supplied.

bwa reports alignmnet The difference between secondary and supplementary is semantic

ADD REPLY
1
Entering edit mode
5.5 years ago
d-cameron ★ 2.9k

The primary alignnent is not always the "left-most" on the query. This behaviour can be changed by supplying the "-5" flag in which case the alignment with the smallest coordinate will be reported as the primary.

ADD COMMENT
0
Entering edit mode

Hi, it shows that bwa mem does not have -5 option.

ADD REPLY
0
Entering edit mode

Check you version. bwa version 0.7.17 (the latest), has the follow listed in the "Input/output options:" section:

   -5            for split alignment, take the alignment with the smallest coordinate as primary
ADD REPLY

Login before adding your answer.

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