Class FractionalIdentityScorer<S extends org.biojava.nbio.core.sequence.template.Sequence<C>,​C extends org.biojava.nbio.core.sequence.template.Compound>

  • Type Parameters:
    S - each Sequence of the alignment pair is of type S
    C - each element of an AlignedSequence is a Compound of type C
    All Implemented Interfaces:
    PairwiseSequenceScorer<S,​C>, Scorer
    Direct Known Subclasses:
    FractionalIdentityInProfileScorer

    public class FractionalIdentityScorer<S extends org.biojava.nbio.core.sequence.template.Sequence<C>,​C extends org.biojava.nbio.core.sequence.template.Compound>
    extends AbstractScorer
    implements PairwiseSequenceScorer<S,​C>
    Implements an algorithm which computes a score for a sequence alignment pair. The reported score is the number of alignment columns which have identical Compounds.
    Author:
    Mark Chapman
    • Constructor Detail

      • FractionalIdentityScorer

        public FractionalIdentityScorer​(PairwiseSequenceAligner<S,​C> aligner)
        Creates a fractional identity scorer for a pair of sequences aligned by the given pairwise sequence aligner.
        Parameters:
        aligner - a pairwise sequence aligner
      • FractionalIdentityScorer

        public FractionalIdentityScorer​(org.biojava.nbio.core.alignment.template.SequencePair<S,​C> pair)
        Creates a fractional identity scorer for an aligned pair of sequences.
        Parameters:
        pair - an aligned pair of sequences
    • Method Detail

      • getQuery

        public S getQuery()
        Description copied from interface: PairwiseSequenceScorer
        Returns the first sequence of the pair.
        Specified by:
        getQuery in interface PairwiseSequenceScorer<S extends org.biojava.nbio.core.sequence.template.Sequence<C>,​C extends org.biojava.nbio.core.sequence.template.Compound>
        Returns:
        the first sequence of the pair
      • getTarget

        public S getTarget()
        Description copied from interface: PairwiseSequenceScorer
        Returns the second sequence of the pair.
        Specified by:
        getTarget in interface PairwiseSequenceScorer<S extends org.biojava.nbio.core.sequence.template.Sequence<C>,​C extends org.biojava.nbio.core.sequence.template.Compound>
        Returns:
        the second sequence of the pair
      • getMaxScore

        public double getMaxScore()
        Description copied from interface: Scorer
        Returns maximum possible score.
        Specified by:
        getMaxScore in interface Scorer
        Returns:
        maximum possible score
      • getMinScore

        public double getMinScore()
        Description copied from interface: Scorer
        Returns minimum possible score.
        Specified by:
        getMinScore in interface Scorer
        Returns:
        minimum possible score