diff --git a/java/src/org/broadinstitute/sting/playground/gatk/walkers/GenotypeAndValidateWalker.java b/java/src/org/broadinstitute/sting/playground/gatk/walkers/GenotypeAndValidateWalker.java index d8c71ebbc..e2a0e4847 100755 --- a/java/src/org/broadinstitute/sting/playground/gatk/walkers/GenotypeAndValidateWalker.java +++ b/java/src/org/broadinstitute/sting/playground/gatk/walkers/GenotypeAndValidateWalker.java @@ -23,9 +23,8 @@ * THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -package org.broadinstitute.sting.oneoffprojects.walkers; +package org.broadinstitute.sting.playground.gatk.walkers; -import com.google.common.collect.ImmutableSet; import org.broad.tribble.util.variantcontext.MutableVariantContext; import org.broad.tribble.util.variantcontext.VariantContext; import org.broad.tribble.vcf.VCFHeader; @@ -46,10 +45,11 @@ import org.broadinstitute.sting.gatk.walkers.genotyper.VariantCallContext; import org.broadinstitute.sting.utils.SampleUtils; import org.broadinstitute.sting.utils.exceptions.UserException; import org.broadinstitute.sting.utils.vcf.VCFUtils; -import sun.management.counter.Variability; import java.util.*; +import static org.broadinstitute.sting.utils.IndelUtils.isInsideExtendedIndel; + /** * Validates the calls on a ROD track using a BAM dataset. * @@ -77,6 +77,12 @@ public class GenotypeAndValidateWalker extends RodWalker= 0) uac.MIN_BASE_QUALTY_SCORE = mbq; if (deletions >= 0) uac.MAX_DELETION_FRACTION = deletions; + if (callConf >= 0) uac.STANDARD_CONFIDENCE_FOR_CALLING = callConf; + if (emitConf >= 0) uac.STANDARD_CONFIDENCE_FOR_EMITTING = emitConf; + + snpEngine = new UnifiedGenotyperEngine(getToolkit(), uac); // Adding the INDEL calling arguments for UG @@ -165,16 +175,18 @@ public class GenotypeAndValidateWalker extends RodWalker 0 && context.getBasePileup().getBases().length < minDepth)) { - // don't count indel extended events multiple times as uncovered. - // if (vcComp.getStart() == ref.getLocus().getStart()) //todo - not sure I want this, may be misleading to filter anything. - counter.numUncovered = 1L; + counter.numUncovered = 1L; return counter; } - if ((vcComp.getFilters().contains("TP") && vcComp.getFilters().contains("FP")) || (!vcComp.getFilters().contains("TP") && !vcComp.getFilters().contains("FP"))) - throw new UserException.BadInput("Variant has the wrong filter annotation -- either missing FP/TP or has both. " + vcComp.getChr() + ":" + vcComp.getStart()); + if (!vcComp.hasAttribute("GV")) + throw new UserException.BadInput("Variant has no GV annotation in the INFO field. " + vcComp.getChr() + ":" + vcComp.getStart()); VariantCallContext call; if ( vcComp.isSNP() ) @@ -189,16 +201,16 @@ public class GenotypeAndValidateWalker extends RodWalker