From 99ad7b2d7136080fd12ce4c4f303e44e058b4160 Mon Sep 17 00:00:00 2001 From: Mark DePristo Date: Fri, 5 Oct 2012 11:49:27 -0700 Subject: [PATCH] GeneralPloidyExact should use indel max alt alleles --- .../gatk/walkers/genotyper/GeneralPloidyExactAFCalculation.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/protected/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/GeneralPloidyExactAFCalculation.java b/protected/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/GeneralPloidyExactAFCalculation.java index f1e38720c..1a51598e2 100644 --- a/protected/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/GeneralPloidyExactAFCalculation.java +++ b/protected/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/GeneralPloidyExactAFCalculation.java @@ -53,6 +53,8 @@ public class GeneralPloidyExactAFCalculation extends ExactAFCalculation { @Override protected VariantContext reduceScope(VariantContext vc) { + final int maxAltAlleles = vc.getType().equals(VariantContext.Type.INDEL) ? MAX_ALTERNATE_ALLELES_FOR_INDELS : MAX_ALTERNATE_ALLELES_TO_GENOTYPE; + // don't try to genotype too many alternate alleles if ( vc.getAlternateAlleles().size() > maxAltAlleles) { logger.warn("this tool is currently set to genotype at most " + maxAltAlleles + " alternate alleles in a given context, but the context at " + vc.getChr() + ":" + vc.getStart() + " has " + (vc.getAlternateAlleles().size()) + " alternate alleles so only the top alleles will be used; see the --max_alternate_alleles argument");