This is a test version of Biostars. For the public version, visit https://www.biostars.org.
VAF filtering in bcftools caller

Hello,

I'd like to filter germline mutations from BCF generated by bcftools calls. If I understand correctly there should be a VAF tag available to filter by, however when I try to add the VAF tag I get an error:

bcftools +fill-tags test.bcf  -- -t bcftools +fill-tags test.bcf  -- -t AF

Warning: cannot add the VAF/VAF1 annotations, the required FORMAT/AD tag is missing at chr1:10352.

and then when I try to add the AD tag I get:

Error parsing "--tags AD": the tag "AD" is not supported

what is the right way of adding VAF to variant calling bcf file (or mpileup)?

Thanks, D

bcftools vaf

You can't fill AD tag from VCF file. This tag is creating when you're calling variants from count of reads. Some people write AD field in INFO column, and you can carry it over to SAMPLE column first.

I see - so rerunning the mpileup this time requesting the AD tag will allow me later to add VAF? is this the right way?

cool, thank you. So I'm doing the following:

bcftools mpileup --redo-BAQ --per-sample-mF -f ref.fa.gz sample.bam -a FORMAT/AD,FORMAT/ADF,FORMAT/ADR,FORMAT/DP,FORMAT/SP,FORMAT/SCR,INFO/AD,INFO/ADF,INFO/ADR,INFO/SCR,FORMAT/DV,FORMAT/DP4,FORMAT/DPR,INFO/DPR | bcftools call --multiallelic-caller --variants-only -Ou -o calls.bcf

bcftools +fill-tags calls.bcf -- -t VAF

would that work? also, to exclude potential germline variants, roughly what VAF should I filter out?

0 answers

No answers yet.

Log in to answer this question.