contextFold.scoring
Class FoldEvaluatorImpl

java.lang.Object
  extended by contextFold.scoring.FoldEvaluatorImpl
All Implemented Interfaces:
FoldEvaluator

public class FoldEvaluatorImpl
extends java.lang.Object
implements FoldEvaluator


Constructor Summary
FoldEvaluatorImpl(FeatureManager featureManager)
           
 
Method Summary
 void differenceFeatureVector(int[] guessFold, int[] goldFold, AbstractFeatureVector diffVector, RNA rna)
          Computes the feature difference between two foldings.
 AbstractFeatureVector differenceFeatureVector(int[] guessFold, int[] goldFold, RNA rna)
           
 float scoreFold(RNA rna, int[] fold)
          Computes the score of a given sequence-folding pair.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FoldEvaluatorImpl

public FoldEvaluatorImpl(FeatureManager featureManager)
Method Detail

scoreFold

public float scoreFold(RNA rna,
                       int[] fold)
Description copied from interface: FoldEvaluator
Computes the score of a given sequence-folding pair.

Specified by:
scoreFold in interface FoldEvaluator
Parameters:
rna - an RNA sequence.
fold - a folding of the sequence.
Returns:
the score of a given sequence-folding pair.

differenceFeatureVector

public void differenceFeatureVector(int[] guessFold,
                                    int[] goldFold,
                                    AbstractFeatureVector diffVector,
                                    RNA rna)
Description copied from interface: FoldEvaluator
Computes the feature difference between two foldings.

Specified by:
differenceFeatureVector in interface FoldEvaluator
Parameters:
guessFold - a predicted folding of the RNA sequence.
goldFold - a known folding of the RNA sequence.
diffVector - a feature vector, which feature weights correspond to feature differences between the two foldings. Negatively weighted features are those that appeared more in the predicted folding, positively weighted features are those that appeared more in the known folding, and zero weighted feature appeared the same in both foldings.
rna - an RNA sequence

differenceFeatureVector

public AbstractFeatureVector differenceFeatureVector(int[] guessFold,
                                                     int[] goldFold,
                                                     RNA rna)
Specified by:
differenceFeatureVector in interface FoldEvaluator