Question: Filter a VCF using fields stored in a different VCF
gravatar for Sean
5.6 years ago by
United States
Sean210 wrote:


Is there a way to filter variants in a VCF based on fields stored in a different VCF without merging the two files first?


I have a VCF file, and I would like to filter the variants by ExAC allele frequencies stored in a different VCF. I know I can use bcftools annotate to merge the allele counts from the ExAC VCF into my own VCF file and then use bcftools filter to filter by allele frequency. However, I'm wondering if there is a way to skip the merging process altogether.

I noticed that bcftools roh has an option called --AF-file which allows you to specify your frequencies in a different file. Does BCFtools or VCFtools offer a similar feature for filtering?

ADD COMMENTlink modified 5.5 years ago by Biostar ♦♦ 20 • written 5.6 years ago by Sean210

just create a filtered Exac and then only keep your variants that are present in the sub-exac ?

ADD REPLYlink written 5.5 years ago by Pierre Lindenbaum133k
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 2570 users visited in the last hour