This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Multiple VCF filtering

Hi!

I have a vcf with 20 samples and I want to remove from it the variants that are commons (with the same zygosity) to all samples. How can I do it?

Thanks

exom illumina wgs vcf

1 answer

Use bcftools view with an exclude/include expression that operates on COUNT(GT="hom") as shown in the examples here: https://samtools.github.io/bcftools/bcftools.html#expressions

If an answer was helpful, you should upvote it; if the answer resolved your question, you should mark it as accepted. You can accept more than one answer if they all work.

Upvote|Bookmark|Accept

Log in to answer this question.