Thanks for the advice! Many of these are actually very useful, but I still wonder - is there a way to get mean BQ, MQ and position, and not the results of the rank sum test?
Hello all!
I would like to extract the following descriptive metrics from BAM:
- mean base quality
- mapping quality
- mean position in read for variant reads
I would like to go through a VCF and find those metrics for variant-supporting reads directly from BAM. I can do it using pysam, but I was wondering if there is an out-of-the-box solution that is ready and perhaps computationally more efficient. Any help is welcome!
Thanks in advance!
P.S. I also know that VarDict Java does it for candidate locations, but sometimes I need it for locations not recognized by VarDict's algorithm. But in general, such an output (TSV) would be perfect.
1 answer
I think GATK variant annotator is able to do this: https://software.broadinstitute.org/gatk/gatkdocs/3.8-0/org_broadinstitute_gatk_tools_walkers_annotator_VariantAnnotator.php
There are a bunch of predefined annotations under: "Annotation Modules" https://software.broadinstitute.org/gatk/gatkdocs/3.8-0/org_broadinstitute_gatk_tools_walkers_annotator_VariantAnnotator.php
mean base quality
mapping quality
mean position in read for variant reads
Log in to answer this question.