public class RealignmentProcessor extends Object implements AlignmentProcessorInterface
TODO: convert target index to genome index. Necessary when there is not a one to one mapping between TODO: alignment and genome.
| Constructor and Description |
|---|
RealignmentProcessor(ConcatSortedAlignmentReader sortedReaders) |
RealignmentProcessor(it.unimi.dsi.fastutil.objects.ObjectListIterator<Alignments.AlignmentEntry> entryIterator) |
| Modifier and Type | Method and Description |
|---|---|
int |
getModifiedCount()
Returns the number of entries actually modified by the processor.
|
int |
getProcessedCount()
Returns the number of entries processed by the processor.
|
Alignments.AlignmentEntry |
nextRealignedEntry(int targetIndex,
int position)
Provides the next processed entry.
|
void |
pushEntryToPool(InfoForTarget tinfo,
int position,
Alignments.AlignmentEntry entry) |
int |
score(Alignments.AlignmentEntry entry,
ObservedIndel indel,
boolean shiftForward,
int currentBestScore,
RandomAccessSequenceInterface genome)
Score the realignment of an entry with respect to a potential indel.
|
void |
setGenome(RandomAccessSequenceInterface genome)
Provide this processor with a compressed genome.
|
void |
setGenome(RandomAccessSequenceInterface genome,
edu.cornell.med.icb.identifier.IndexedIdentifier targetIdentifiers) |
public RealignmentProcessor(ConcatSortedAlignmentReader sortedReaders)
public RealignmentProcessor(it.unimi.dsi.fastutil.objects.ObjectListIterator<Alignments.AlignmentEntry> entryIterator)
public int getModifiedCount()
AlignmentProcessorInterfacegetModifiedCount in interface AlignmentProcessorInterfacepublic int getProcessedCount()
AlignmentProcessorInterfacegetProcessedCount in interface AlignmentProcessorInterfacepublic Alignments.AlignmentEntry nextRealignedEntry(int targetIndex, int position) throws IOException
AlignmentProcessorInterfacenextRealignedEntry in interface AlignmentProcessorInterfacetargetIndex - index of the reference sequence, similar to a call to AlignmentReaderI.skipTo()position - position on the reference sequence, similar to a call to AlignmentReaderI.skipTo()IOException - If an error occurred reading the alignment.public final int score(Alignments.AlignmentEntry entry, ObservedIndel indel, boolean shiftForward, int currentBestScore, RandomAccessSequenceInterface genome)
entry - The entry to score as if it was realigned with respect to the indelindel - The indel under consideration.shiftForward - Whether the indel should be introduced by shifting bases forwardcurrentBestScore - The current maximum score over a set of indels under consideration. @return The score obtained when realigning the entry with respect to the provided indel.genome - The genome to use to lookup reference basespublic void pushEntryToPool(InfoForTarget tinfo, int position, Alignments.AlignmentEntry entry)
public void setGenome(RandomAccessSequenceInterface genome)
AlignmentProcessorInterfacesetGenome in interface AlignmentProcessorInterfacegenome - The genome corresponding to the alignmentpublic void setGenome(RandomAccessSequenceInterface genome, edu.cornell.med.icb.identifier.IndexedIdentifier targetIdentifiers)
Copyright © 2017 Campagne Laboratory. All rights reserved.