I may have also misinterpreted the question if you are asking for the frequency of variants across multiple BAMs, then it is just conventional AF (allele frequency, e.g. amongst the population) instead of VAF ("variant allele fraction")
Dear all, Do you know of any tool that provides allelic frequency information within a haplotype?
> Input: Bam files
> Output: allele1 - pos A/T AF=0.5, pos A/C AF=0.3, pos C/G AF=0.98
allele2 - pos A/C AF=0.3, pos..........
I tried Shorah tool, but if I load bam file into that program, I receive information: No reads detected in these region. But there are reads.
Thank you
1 answer
you may want "variant allele fraction" (VAF). it is just calculated from "allele depth" which you can do manually from data in your VCF, or can use bcftools to add this. if you run a standard variant caller (i can't advise what tool you want to use to call variants), and generated a VCF, you can use bcftools to add the VAF information
example copied from https://samtools.github.io/bcftools/howtos/plugin.fill-tags.html
# Annotate with allelic fraction
bcftools +fill-tags in.bcf -Ob -o out.bcf -- -t FORMAT/VAF
the example above uses BCF and outputs BCF, but you can likely use this on a VCF file and output to e.g. stdout
bcftools +fill-tags in.vcf -- -t FORMAT/VAF
Thank you, but I am looking for solution to get haplotypes with alellic frequency. Find all snps (mulitalelic) with them frequency (VAF) on one read. Similar to assembly but with these information on output. For this VAF I am using combination of samtools mpileup and Varscan. Best
Log in to answer this question.