From 3635606cd82d88b521488eae54d3c11c982a4746 Mon Sep 17 00:00:00 2001 From: delangel Date: Tue, 8 Feb 2011 17:33:29 +0000 Subject: [PATCH] Temp checkin just for experimentation: exposed probabilistic alignment parameters to command line interface to make it easier to experiment on their effects, although a full scrap/rewrite of this should be coming soon. git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@5218 348d0f76-0448-11de-a6fe-93d51630548a --- .../DindelGenotypeLikelihoodsCalculationModel.java | 7 ++----- .../walkers/genotyper/UnifiedArgumentCollection.java | 11 +++++++++++ 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/DindelGenotypeLikelihoodsCalculationModel.java b/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/DindelGenotypeLikelihoodsCalculationModel.java index bf23640e5..c6b80c308 100755 --- a/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/DindelGenotypeLikelihoodsCalculationModel.java +++ b/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/DindelGenotypeLikelihoodsCalculationModel.java @@ -48,9 +48,6 @@ import java.util.*; public class DindelGenotypeLikelihoodsCalculationModel extends GenotypeLikelihoodsCalculationModel { private final int maxReadDeletionLength = 3; - private final double insertionStartProbability = 1e-3; - private final double insertionEndProbability = 0.5; - private final double alphaDeletionProbability = 1e-3; private final int HAPLOTYPE_SIZE = 80; private final int minIndelCountForGenotyping; @@ -65,8 +62,8 @@ public class DindelGenotypeLikelihoodsCalculationModel extends GenotypeLikelihoo private List alleleList; protected DindelGenotypeLikelihoodsCalculationModel(UnifiedArgumentCollection UAC, Logger logger) { super(UAC, logger); - model = new HaplotypeIndelErrorModel(maxReadDeletionLength, insertionStartProbability, - insertionEndProbability, alphaDeletionProbability, HAPLOTYPE_SIZE, false, DEBUGOUT); + model = new HaplotypeIndelErrorModel(maxReadDeletionLength, UAC.INSERTION_START_PROBABILITY, + UAC.INSERTION_END_PROBABILITY, UAC.ALPHA_DELETION_PROBABILITY, HAPLOTYPE_SIZE, false, DEBUGOUT); alleleList = new ArrayList(); getAlleleListFromVCF = UAC.GET_ALLELES_FROM_VCF; minIndelCountForGenotyping = UAC.MIN_INDEL_COUNT_FOR_GENOTYPING; diff --git a/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/UnifiedArgumentCollection.java b/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/UnifiedArgumentCollection.java index 622c42406..0514d2ad8 100755 --- a/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/UnifiedArgumentCollection.java +++ b/java/src/org/broadinstitute/sting/gatk/walkers/genotyper/UnifiedArgumentCollection.java @@ -99,6 +99,14 @@ public class UnifiedArgumentCollection { @Argument(fullName = "indel_heterozygosity", shortName = "indelHeterozygosity", doc = "Heterozygosity for indel calling", required = false) public double INDEL_HETEROZYGOSITY = 1.0/8000; + @Argument(fullName = "insertionStartProbability", shortName = "insertionStartProbability", doc = "Heterozygosity for indel calling", required = false) + public double INSERTION_START_PROBABILITY = 1e-3; + @Argument(fullName = "insertionEndProbability", shortName = "insertionEndProbability", doc = "Heterozygosity for indel calling", required = false) + public double INSERTION_END_PROBABILITY = 0.5; + @Argument(fullName = "alphaDeletionProbability", shortName = "alphaDeletionProbability", doc = "Heterozygosity for indel calling", required = false) + public double ALPHA_DELETION_PROBABILITY = 1e-3; + + public UnifiedArgumentCollection clone() { UnifiedArgumentCollection uac = new UnifiedArgumentCollection(); @@ -121,6 +129,9 @@ public class UnifiedArgumentCollection { uac.GET_ALLELES_FROM_VCF = GET_ALLELES_FROM_VCF; uac.MIN_INDEL_COUNT_FOR_GENOTYPING = MIN_INDEL_COUNT_FOR_GENOTYPING; uac.INDEL_HETEROZYGOSITY = INDEL_HETEROZYGOSITY; + uac.INSERTION_START_PROBABILITY = INSERTION_START_PROBABILITY; + uac.INSERTION_END_PROBABILITY = INSERTION_END_PROBABILITY; + uac.ALPHA_DELETION_PROBABILITY = ALPHA_DELETION_PROBABILITY; return uac; }