Is there any way to get the mismatch positions in the reads mapped by the Bowtie2 ?
1
0
Entering edit mode
3.1 years ago
Joyanta • 0

Hello, I am trying to get the check the positions of the mapped reads which are detected as a mismatch by the Bowtie2 aligner. I can separate the reads based on mismatch numbers but could not find any resource on how to find out their positions in the read.

sequence mapping alignment genomics • 990 views
ADD COMMENT
1
Entering edit mode

You should be able to parse the CIGAR string included in the alignment.

ADD REPLY
0
Entering edit mode

Thanks.

ADD REPLY
0
Entering edit mode
3.1 years ago

The MD tag will have that information in a simple format:

See here:

https://github.com/vsbuffalo/devnotes/wiki/The-MD-Tag-in-BAM-Files

relevant excerpt:

Thus, this information is carried in the MD tag. A SNP looks like:

10A3T0T10

Here, there are three SNPs:

  • 11 bases in from the aligned portion of the read, the reference has an A and the read has what ever base is at the 10th > position (excluding softclips).

  • 15 bases in there's a T in the reference.

  • 16 bases in there's a T in the reference. Note that 0s are use used to indicate positions of neighboring SNPs.

note how the MD above tells you what mismatches related to the reference, you'll still need to parse out your read to find what your SNP actually.

ADD COMMENT

Login before adding your answer.

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