public class SamComparison extends Object implements SamComparisonInterface
| Modifier and Type | Field and Description |
|---|---|
protected int |
comparisonFailureCount |
protected boolean |
countComparisonFailures |
protected boolean |
outputFailedComparisons |
protected int |
readNum
Running totals, etc.
|
| Constructor and Description |
|---|
SamComparison()
Create a SamComparison.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compare(htsjdk.samtools.SAMRecord expectedSamRecord,
htsjdk.samtools.SAMRecord actualSamRecord,
Alignments.AlignmentEntry gobyAlignment)
Compare expectedSamRecord vs actualSamRecord.
|
void |
dumpComparison(htsjdk.samtools.SAMRecord expectedSamRecord,
htsjdk.samtools.SAMRecord actualSamRecord,
Alignments.AlignmentEntry gobyAlignment)
Dump the details of expectedSamRecord and actualSamRecord (and gobyAlignment if available).
|
int |
finished() |
int |
getComparisonFailureCount()
Return how many comparison failures have been found since reset() was last called.
|
List<String> |
getComparisonFailures() |
int |
getCurrentComparisonScore()
The comparison failure score of the last comparison.
|
int |
getReadNum()
Return how many reads have been compared since reset() was last called.
|
boolean |
isAllowSourceNs()
Get if the source base can be and and thd destination base be a non-N.
|
boolean |
isCanonicalMdzForComparison()
Get if canonical MD:Z comparisons will be made.
|
boolean |
isCheckMate()
Get if the details about mate reads will be checked.
|
boolean |
isCountComparisonFailures()
Get if a failure should be counted.
|
boolean |
isMappedQualitiesPreserved()
Get if it is assumed that the compact file created from the BAM/SAM
file preserved mapped qualities.
|
boolean |
isOutputFailedComparisons()
Get if details of failed comparisons should be written to stdout automatically.
|
boolean |
isReadNamesPreserved()
Get if read names were preserved and thus we can use them to aid with comparison.
|
boolean |
isSoftClipsPreserved()
Get if it is assumed that the compact file created from the BAM/SAM
file preserved soft clips.
|
void |
reset()
Call this one time before at the start of a large number of comparisons (such as before comparing
one entire file with another).
|
void |
setAllowSourceNs(boolean allowSourceNs)
Set if the source base can be and and thd destination base be a non-N.
|
void |
setCanonicalMdzForComparison(boolean canonicalMdzForComparison)
Set if canonical MD:Z comparisons will be made.
|
void |
setCheckMate(boolean checkMate)
Set if the details about mate reads will be checked.
|
void |
setCountComparisonFailures(boolean countComparisonFailures)
Set if a failure should be counted.
|
void |
setMappedQualitiesPreserved(boolean mappedQualitiesPreserved)
Set if it is assumed that the compact file created from the BAM/SAM
file preserved mapped qualities.
|
void |
setOutputFailedComparisons(boolean outputFailedComparisons)
Set if details of failed comparisons should be written to stdout automatically.
|
void |
setReadNamesPreserved(boolean readNamesPreserved)
Set if read names were preserved and thus we can use them to aid with comparison.
|
void |
setSoftClipsPreserved(boolean softClipsPreserved)
Set if it is assumed that the compact file created from the BAM/SAM
file preserved soft clips.
|
String |
usableReadOf(htsjdk.samtools.SAMRecord samRecord) |
protected int readNum
protected int comparisonFailureCount
protected boolean outputFailedComparisons
protected boolean countComparisonFailures
public void reset()
reset in interface SamComparisonInterfacepublic boolean isMappedQualitiesPreserved()
isMappedQualitiesPreserved in interface SamComparisonInterfacepublic void setMappedQualitiesPreserved(boolean mappedQualitiesPreserved)
setMappedQualitiesPreserved in interface SamComparisonInterfacemappedQualitiesPreserved - if it is assumed...public boolean isSoftClipsPreserved()
isSoftClipsPreserved in interface SamComparisonInterfacepublic void setSoftClipsPreserved(boolean softClipsPreserved)
setSoftClipsPreserved in interface SamComparisonInterfacesoftClipsPreserved - if it is assumed ...public boolean isCheckMate()
isCheckMate in interface SamComparisonInterfacepublic void setCheckMate(boolean checkMate)
setCheckMate in interface SamComparisonInterfacecheckMate - if mates will be checkedpublic boolean isCanonicalMdzForComparison()
isCanonicalMdzForComparison in interface SamComparisonInterfacepublic void setCanonicalMdzForComparison(boolean canonicalMdzForComparison)
setCanonicalMdzForComparison in interface SamComparisonInterfacecanonicalMdzForComparison - if ...public int getReadNum()
getReadNum in interface SamComparisonInterfacepublic int getComparisonFailureCount()
getComparisonFailureCount in interface SamComparisonInterfacepublic boolean isOutputFailedComparisons()
public void setOutputFailedComparisons(boolean outputFailedComparisons)
outputFailedComparisons - if ...public boolean isCountComparisonFailures()
public void setCountComparisonFailures(boolean countComparisonFailures)
public int getCurrentComparisonScore()
public boolean isReadNamesPreserved()
isReadNamesPreserved in interface SamComparisonInterfacepublic void setReadNamesPreserved(boolean readNamesPreserved)
setReadNamesPreserved in interface SamComparisonInterfacereadNamesPreserved - if...public boolean isAllowSourceNs()
isAllowSourceNs in interface SamComparisonInterfacepublic void setAllowSourceNs(boolean allowSourceNs)
setAllowSourceNs in interface SamComparisonInterfacepublic int compare(htsjdk.samtools.SAMRecord expectedSamRecord,
htsjdk.samtools.SAMRecord actualSamRecord,
Alignments.AlignmentEntry gobyAlignment)
compare in interface SamComparisonInterfaceexpectedSamRecord - the expected sam recordactualSamRecord - the actual sam recordgobyAlignment - the actual goby alignment recordpublic int finished()
finished in interface SamComparisonInterfacepublic void dumpComparison(htsjdk.samtools.SAMRecord expectedSamRecord,
htsjdk.samtools.SAMRecord actualSamRecord,
Alignments.AlignmentEntry gobyAlignment)
expectedSamRecord - the expected sam recordactualSamRecord - the actual sam recordgobyAlignment - the actual goby alignment recordpublic String usableReadOf(htsjdk.samtools.SAMRecord samRecord)
Copyright © 2017 Campagne Laboratory. All rights reserved.