This is a test version of Biostars. For the public version, visit https://www.biostars.org.
GATK SNP calling from BAM

I used vg giraffe to align long reads to a graph, generating a GAM file. Then I converted the GAM to a BAM file. I tried using GATK to call SNPs from the BAM file, but no SNPs were detected. However, when inspecting the CIGAR field, I can see many mismatches.

vg

just because there are some mismatches in the cigar doesn't mean a variant will be called: there must be a minimal set of data to call the variant : quality, depth, clipping, etc...

If you're getting a non-empty BAM with correct-looking CIGAR strings and reasonable coverage, I would highly doubt that the breakdown in the pipeline is the mapping. My recommendation would be to look closely at the logs from GATK to make sure it's not telling you about a data issue such as a mismatching reference genome or a missing read group.

1 answer

From your described workflow the issue could be that sam flags are getting dropped at surjection resulting in 0 "properly paired" reads. There are a few alternative solutions here https://github.com/vgteam/vg/issues/4563. The ones I posted are for bcftools mpileup but surely you can find a specular GATK solution.

Log in to answer this question.