If you happen to see a question you know the answer to, please do chime in and help your fellow community members. We encourage our fourm members to be more involved, jump in and help out your fellow researchers with their questions. GATK forum is a community forum and helping each other with using GATK tools and research is the cornerstone of our success as a genomics research community.We appreciate your help!

Test-drive the GATK tools and Best Practices pipelines on Terra

Check out this blog post to learn how you can get started with GATK and try out the pipelines in preconfigured workspaces (with a user-friendly interface!) without having to install anything.

Removing annotations/genotype filters from a VCF?

bbimberbbimber HomeMember


We're preparing VCFs for public release. Our working VCF has a considerable amount of both info and format field annotations and also filters in both. We also have another header lines, such as the GATKCommand, which should be removed. I'd like to prepare a minimal VCF that strips all information except a minimal whitelist of annotations. A handful of GATK tools have options to help here. SelectVariants will allow me to exclude filtered (site-level filters), but this doesnt clean up filtered genotypes (even if genotypes are set to no call). It appears I could run VariantAnnotator with --excludeAnnotation; however, I think I would need to apply a blacklist (i.e. need to target each one to remove), as opposed to a whitelist of those to keep, which would be a little more robust. I could probably make a simple walker that does this, but if existing tools can be combined to do this I'd prefer not to. Are there existing features that could help, specifically with stripping out annotations and filters from INFO and FORMAT fields?



  • shleeshlee CambridgeMember, Broadie ✭✭✭✭✭
    edited May 2017

    Hi @bbimber,

    You can see if Picard's MakeSitesOnlyVcf simplifies your VCF in a manner that allows your whitelisting approach. It will retain only the first eight columns of the VCF. You could also check out CombineVariants' --minimalVCF option that removes INFO, FORMAT and sample-level (genotype) fields. This tool may change some of your annotations so be on the watch for that.

  • bbimberbbimber HomeMember

    Thanks - I think GATK also has an option (perhaps the core Command-line arguments) to output a sites-only VCF. These are close, but I think to do this properly we're going to need to make our own walker to do things like retain genotypes, but strip other information.

  • SheilaSheila Broad InstituteMember, Broadie admin

    Hi Ben,

    Yes, I think you will need to write something of your own. I am pretty sure no GATK tool does what you want.


Sign In or Register to comment.