5 Working with SAMtools and BCFtools Part 2
Exercise
- Create a new alignment using
bwa aln
. - Do a quick comparison using the SN metrics from
samtools stats
of thebwa aln
BAM and the previousbwa mem
BAM. What is one metric that changed the most and why might this be? - Filter the
bwa aln
alignment in order to only keep reads with a mapping quality above a threshold of your choice.- Do a quick side-by-side comparison of coverage of your new and old
bwa aln
alignments usingbwa stats
. How does introducing a quality threshold lead to a difference here? Can you explain the pros and cons of filtering by mapping quality in terms of sensitivity and specificity? - Choosing an arbitrary area along Bordetella’s single contig, what is one difference you can spot between your new and old
bwa aln
alignments besides read depth? (Hint: take a look at bit flags and positions, and consult IGV’s coloring scheme.)
- Do a quick side-by-side comparison of coverage of your new and old