I have a single sample BAM file and sometimes there may be more than one allele at a single position (either true or sequencing error) I am trying to output the read counts supporting each alternate allele at site.
samtools mpileup -ugf <ref.fa> <bamfile> | bcftools call --ploidy 1 -AmO v
(htslib version 1.4)
For example it outputs like this:
Chromosome 3913737 . G A 24.8295 . DP=91;VDB=0.322194;SGB=-0.693143;RPB=0.982146;MQB=1;MQSB=1;BQB=0.99872;MQ0F=0;AC=0;AN=1;DP4=21,8,26,12;MQ=60 GT:PL 0:255,255
From the header it looks like the AC
info flag should output this information (##INFO=<ID=AC,Number=A,Type=Integer,Description="Allele count in genotypes for each ALT allele, in the same order as listed">
)
However as you can see the DP4 looks like there are many alternare allele reads present but AC=0
.
Does anyone have any suggestions?