update walkers so that onTraversalDone works (it now takes an arg)
git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@235 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
parent
3896cc8f17
commit
907c183242
|
|
@ -45,7 +45,7 @@ public class AlignedReadsHistoWalker extends ReadWalker<Integer, Integer> {
|
||||||
return value + sum;
|
return value + sum;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void onTraversalDone() {
|
public void onTraversalDone(Integer result) {
|
||||||
int curTotal = 0;
|
int curTotal = 0;
|
||||||
for ( int i = 0; i < alignCounts.length; i++ ) {
|
for ( int i = 0; i < alignCounts.length; i++ ) {
|
||||||
curTotal += alignCounts[i];
|
curTotal += alignCounts[i];
|
||||||
|
|
|
||||||
|
|
@ -159,7 +159,7 @@ public class AlleleFrequencyMetricsWalker extends LocusWalker<AlleleFrequencyEst
|
||||||
out.println();
|
out.println();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void onTraversalDone()
|
public void onTraversalDone(String result)
|
||||||
{
|
{
|
||||||
printMetrics();
|
printMetrics();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,12 +4,6 @@ import net.sf.samtools.SAMRecord;
|
||||||
import org.broadinstitute.sting.gatk.LocusContext;
|
import org.broadinstitute.sting.gatk.LocusContext;
|
||||||
import org.broadinstitute.sting.gatk.walkers.ReadWalker;
|
import org.broadinstitute.sting.gatk.walkers.ReadWalker;
|
||||||
import org.broadinstitute.sting.gatk.walkers.WalkerName;
|
import org.broadinstitute.sting.gatk.walkers.WalkerName;
|
||||||
import org.broadinstitute.sting.utils.Utils;
|
|
||||||
import edu.mit.broad.picard.reference.ReferenceSequence;
|
|
||||||
|
|
||||||
import java.util.Iterator;
|
|
||||||
import java.util.List;
|
|
||||||
import static java.lang.reflect.Array.*;
|
|
||||||
|
|
||||||
@WalkerName("Base_Quality_Dump")
|
@WalkerName("Base_Quality_Dump")
|
||||||
public class BaseQualityDumpWalker extends ReadWalker<Integer, Integer> {
|
public class BaseQualityDumpWalker extends ReadWalker<Integer, Integer> {
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,7 @@ public class BaseQualityHistoWalker extends ReadWalker<Integer, Integer> {
|
||||||
return value + sum;
|
return value + sum;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void onTraversalDone() {
|
public void onTraversalDone(Integer result) {
|
||||||
int lastNonZero = -1;
|
int lastNonZero = -1;
|
||||||
for ( int i = this.qualCounts.length-1; i >= 0; i-- ) {
|
for ( int i = this.qualCounts.length-1; i >= 0; i-- ) {
|
||||||
if ( this.qualCounts[i] > 0 ) {
|
if ( this.qualCounts[i] > 0 ) {
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,7 @@ public class MismatchHistoWalker extends ReadWalker<Integer, Integer> {
|
||||||
return value + sum;
|
return value + sum;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void onTraversalDone() {
|
public void onTraversalDone(Integer result) {
|
||||||
for ( int i = 0; i < mismatchCounts.length; i++ )
|
for ( int i = 0; i < mismatchCounts.length; i++ )
|
||||||
out.println((i+1) + "\t" + mismatchCounts[i]);
|
out.println((i+1) + "\t" + mismatchCounts[i]);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue