This is a test version of Biostars. For the public version, visit https://www.biostars.org.
allele frequency bcf tools

Hi, I would like to get the read counts for the ref and alt allele in a vcf file using bcf tools call.
I use this command:

bcftools mpileup -Ou -f genome.fa {input.bam} | bcftools call -m -o {output.vcf}

But I don't see the counts for the alt allele in the output, only total DP.

Any advice would be greatly appreciated.

snp variant calling

1 answer

Hi jh,

You need to also output the AD tag. The full command:

bcftools mpileup \
  --redo-BAQ \
  --min-BQ 30 \
  --per-sample-mF \
  --annotate FORMAT/AD,FORMAT/ADF,FORMAT/ADR,FORMAT/DP,FORMAT/SP,INFO/AD,INFO/ADF,INFO/ADR \
  -f "${Ref_FASTA}" \
  Aligned_Sorted_PCRDuped_FiltMAPQ.bam |\
    bcftools call \
      --multiallelic-caller \
      --variants-only \
      -Ob > Aligned_Sorted_PCRDuped_FiltMAPQ.bcf ;

Kevin

Log in to answer this question.