Fix UG's simple indel calculation model so that deletions are created correctly

git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@4072 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
ebanks 2010-08-20 15:35:47 +00:00
parent 51678d48e4
commit 2ef2f1b24a
2 changed files with 2 additions and 2 deletions

View File

@ -69,7 +69,7 @@ public class SimpleIndelCalculationModel extends GenotypeCalculationModel {
if ( bestEvent.charAt(0) == '-' ) {
alleles.add( Allele.create(Allele.NULL_ALLELE_STRING,false) );
alleles.add( Allele.create(bestEvent.substring(1), true ));
loc = GenomeLocParser.setStop(loc, loc.getStop() + bestEvent.length()-2);
loc = GenomeLocParser.setStop(loc, loc.getStop() + bestEvent.length()-1);
} else
throw new StingException("Internal error (probably a bug): event does not conform to expected format: "+ bestEvent);
}
@ -78,6 +78,7 @@ public class SimpleIndelCalculationModel extends GenotypeCalculationModel {
-1.0 /* log error */, null /* filters */, null /* attributes */);
vcc = new VariantCallContext(vc,true);
vcc.setRefBase(ref[0]);
/*
if ( totalIndels > 0 ) {
System.out.println("Calling: "+bestEvent+" ["+bestIndelCount+"/"+totalIndels+"/"+totalCoverage+"] at "+loc);

View File

@ -34,7 +34,6 @@ import org.broadinstitute.sting.gatk.walkers.annotator.VariantAnnotatorEngine;
import org.broadinstitute.sting.utils.*;
import org.broadinstitute.sting.commandline.*;
import org.broadinstitute.sting.utils.vcf.VCFUtils;
import org.broadinstitute.sting.utils.genotype.*;
import org.broadinstitute.sting.utils.genotype.vcf.*;
import java.util.*;