Question: Filtering Vcf File For Fixed Substitutions
gravatar for Rubal7
7.1 years ago by
Rubal7770 wrote:

Hello Everyone,

I have 2 VCF files for 2 separate populations and I would like to look for candidate functional sites that are fixed in each population and not present in the other VCFs. Ensembls variant effect predictor (VEP) can take VCF files directly. So is there a straightforward way to create a new VCF from each population VCF that only contains sites where all individuals carry the alternative allele (1/1)? I can't see an option on VCFtools that does this. This isnt exactly what I want but close enough I think to be very useful. Ideally I want a vcf file for a population containing only sites where they are fixed for alternate (1/1) and the other population is fixed for the reference allele (0/0). I think with VCFtools I can filter one file based on another, but not sure how to do the filtering to specify keep sites in one file if all individuals are 1/1 and all individuals in other file are 0/0. In other words only keeping sites with substitutions. Maybe there is a way in VCFtools I don't see.

Thanks in advance for your help!

Best regards,


vcf filter frequency allele • 3.2k views
ADD COMMENTlink modified 7.1 years ago by Adam990 • written 7.1 years ago by Rubal7770
gravatar for Gabriel R.
7.1 years ago by
Gabriel R.2.7k
Danmarks Tekniske Universitet
Gabriel R.2.7k wrote:

Maybe you could use to merge your multiple VCF files and run a some sort of grep for non-1/1 genotypes.

ADD COMMENTlink written 7.1 years ago by Gabriel R.2.7k
gravatar for Adam
7.1 years ago by
United States
Adam990 wrote:

In VCFtools, can't you just use the --non-ref-af and --max-non-ref-af options on each file separately, and then intersect the results?

ADD COMMENTlink written 7.1 years ago by Adam990

ah that makes sense, thank you!

ADD REPLYlink written 7.1 years ago by Rubal7770
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: 1683 users visited in the last hour