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.
Notice:
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.

Trouble combining SNP and (hard filtered) indels vcfs for same samples

Using UG I have jointly called a vcf for about 830 subjects and am trying to filter it using VQSR. Because the data is targeted capture (and the caller is UG), I haven't had success using the mixture model approach for indels and instead used hard filters (mixture approach worked fine for SNPs). So, I now have nice filter-status annotated snp and indel vcf files and just want to combine them into a single vcf, but GATK throws an error. I am using the following syntax:

-T CombineVariants \
-V /home/UG_2456bams_833sub_all_filtered_indels.vcf \
-V /home/UG_2456bams_833sub_all_filtered_SNPs.vcf \
-o /home/UG_2456bams_833sub_all_fin.vcf \

And receiving the following error:

ERROR MESSAGE: Duplicate sample names were discovered but no genotypemergeoption was supplied. To combine samples without merging specify --genotypemergeoption UNIQUIFY. Merging duplicate samples without specified priority is unsupported, but can be achieved by specifying --genotypemergeoption UNSORTED.

I take it I should include a --genotypemergeoption argument? If so, which one? I ma a bit confused as to why this would be required as I am not really 'merging' genotypes, but rather appending them.

Many thanks,
Daniel

Best Answers

Answers

  • Hi again,
    I implemented the suggested solution using "-genotypemergeoption UNSORTED" and now I am getting the following error:

    ERROR MESSAGE: Key FILTER found in VariantContext field FILTER at chr1:19198687 but this key isn't defined in the VCFHeader. We require all VCFs to have complete VCF headers by default.

    After looking at the headers of the indel and SNP vcf files, I think I understand the problem, but am not certain of the solution. I believe the problem is due to the fact that I hard filtered the indels but used the mixture model-based VQSR method for the SNPs. Thus, the header is different between the two files. Specifically, looking at the "##FILTER" lines of the headers, the indel file reads:

    FILTER=<ID="FILTER ",Description="QD < 2.0 || FS > 200.0 || ReadPosRankSum < -20.0">

    FILTER=<ID=LowQual,Description="Low quality">

    while the SNP file reads:

    FILTER=<ID=LowQual,Description="Low quality">

    FILTER=<ID=VQSRTrancheSNP99.00to99.90,Description="Truth sensitivity tranche level for SNP model at VQS Lod: -7.2427 <= x < -0.103">

    FILTER=<ID=VQSRTrancheSNP99.90to100.00+,Description="Truth sensitivity tranche level for SNP model at VQS Lod < -36.892">

    FILTER=<ID=VQSRTrancheSNP99.90to100.00,Description="Truth sensitivity tranche level for SNP model at VQS Lod: -36.892 <= x < -7.2427">

    Any suggestions how to combine these two files? Or will an alternate approach be needed?

    Best,
    Daniel

Sign In or Register to comment.