Heads up:
We’re moving the GATK website, docs and forum to a new platform. Read the full story and breakdown of key changes on this blog.
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.

select intersection, merged VCF files

NobuhikoNobuhiko Member
edited October 2018 in Ask the GATK team


I am using GATK3 and trying to compare two samples. I have a merged vcf file of two samples.
I tried running below protocol.

java -jar GenomeAnalysisTK.jar -T SelectVariants \
-R hg19.fasta \
-V C01.vcf \
-select 'set == "Intersection";’ \
-o C01._invertselect.vcf \

I got invertselect files, but it detected not only the difference of genotype. It detected the difference of filtered depth, too.

For example,

chr1    12783   .   G   A   341.69  PASS    AC=4;AF=1;AN=4;DP=304;FS=0;MQ=12.58;MQRankSum=1.953;QD=1.12;ReadPosRankSum=2.964;SOR=2.584  GT:AD:AF:DP:GP:GQ:PL    

How can i detect the difference of only genotype ?
I do appreciate your help.

Post edited by shlee on


  • shleeshlee CambridgeMember, Broadie ✭✭✭✭✭

    Hi @Nobuhiko,

    It sounds like you want to get only those genotypes that differ between two samples. I think I went through this exercise two years ago and it is not straight-forward with GATK. I would recommend using the external RTG-Tools vcfeval. Be sure to NOT use the --squash-ploidy option to match the genotype identically. Using the --squash-ploidy option allows you to match on the variant allele without regard to zygosity. This is useful if your caller isn't great at differentiating het versus hom-var.

Sign In or Register to comment.