Package org.biojava.nbio.alignment
Class SubstitutionMatrixScorer<S extends Sequence<C>,C extends Compound>
java.lang.Object
org.biojava.nbio.alignment.template.AbstractScorer
org.biojava.nbio.alignment.SubstitutionMatrixScorer<S,C>
- Type Parameters:
S-C-
- All Implemented Interfaces:
PairwiseSequenceScorer<S,,C> Scorer
public class SubstitutionMatrixScorer<S extends Sequence<C>,C extends Compound>
extends AbstractScorer
implements PairwiseSequenceScorer<S,C>
Scores using a substitution matrix. Specifically, the score is the sum of the substitution matrix entries
corresponding to the alignment. Gaps are scored according to the substitution matrix, just as matches and mismatches.
- Author:
- dmyersturnbull
-
Constructor Summary
ConstructorsConstructorDescriptionSubstitutionMatrixScorer(SequencePair<S, C> pair, SubstitutionMatrix<C> matrix) -
Method Summary
Methods inherited from class org.biojava.nbio.alignment.template.AbstractScorer
getDistance, getDistance, getSimilarity, getSimilarityMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.biojava.nbio.alignment.template.Scorer
getDistance, getDistance, getSimilarity, getSimilarity
-
Constructor Details
-
SubstitutionMatrixScorer
-
-
Method Details
-
getMaxScore
Description copied from interface:ScorerReturns maximum possible score.- Specified by:
getMaxScorein interfaceScorer- Returns:
- The maximum score the query could be assigned when aligned against any target sequence.
-
getMinScore
Description copied from interface:ScorerReturns minimum possible score.- Specified by:
getMinScorein interfaceScorer- Returns:
- The minimum score the query could be assigned when aligned against any target sequence.
-
getScore
Description copied from interface:ScorerReturns score resulting from algorithm. This should normalize between 0 and 1 by calculating (Scorer.getScore()-Scorer.getMinScore()) / (Scorer.getMaxScore()-Scorer.getMinScore()). -
getQuery
Description copied from interface:PairwiseSequenceScorerReturns the first sequence of the pair. -
getTarget
Description copied from interface:PairwiseSequenceScorerReturns the second sequence of the pair.
-