Implements a probabilistic measure for comparing two words. More...
#include <SimilarityMeasures.h>
Public Member Functions | |
| WordPairComparison (int rank, const StringSimilarityMeasure *sm) | |
| Constructor.   | |
| vector< double > | distrEstimate (int minLen, int maxLen, int nSamples=1000) const | 
| Estimates the distribution of the distances (similarities) between two randomly generated words.   | |
| double | comparePair (const Word &w1, const Word &w2, const vector< double > &measureDistr) const | 
| Compare the pair of words using probabilistic measure.   | |
| double | comparePair (const Word &w1, const Word &w2) const | 
| Compare the pair of words using similarity measure.   | |
Private Member Functions | |
| WordPairComparison (const WordPairComparison &) | |
| WordPairComparison & | operator= (const WordPairComparison &) | 
Private Attributes | |
| const StringSimilarityMeasure * | pSSM | 
| int | theRank | 
Implements a probabilistic measure for comparing two words.
Basic Idea: ...
Definition at line 37 of file SimilarityMeasures.h.
| WordPairComparison::WordPairComparison | ( | int | rank, | |
| const StringSimilarityMeasure * | sm | |||
| ) |  [inline] | 
        
Constructor.
| rank | - the rank of a free group | |
| sm | - pointer to the corresponding similarity measure. | 
Definition at line 45 of file SimilarityMeasures.h.
| WordPairComparison::WordPairComparison | ( | const WordPairComparison & | ) |  [private] | 
        
Compare the pair of words using similarity measure.
| w1 | - the first word | |
| w2 | - the second word. | 
| double WordPairComparison::comparePair | ( | const Word & | w1, | |
| const Word & | w2, | |||
| const vector< double > & | measureDistr | |||
| ) | const | 
Compare the pair of words using probabilistic measure.
| w1 | - the first word | |
| w2 | - the second word. | |
| measureDistr | - distribution of the distance between two random words | 
w1 and w2 been generated independently | vector<double> WordPairComparison::distrEstimate | ( | int | minLen, | |
| int | maxLen, | |||
| int |  nSamples = 1000 | |||
| ) | const | 
Estimates the distribution of the distances (similarities) between two randomly generated words.
| minLen | - the minimal length of a randomly generated word | |
| maxLen | - the maximal length of a randomly generated word | |
| nSamples | - the number of pair samples to be generated (1000 is the default value). | 
| WordPairComparison& WordPairComparison::operator= | ( | const WordPairComparison & | ) |  [private] | 
        
const StringSimilarityMeasure* WordPairComparison::pSSM [private] | 
        
Definition at line 76 of file SimilarityMeasures.h.
int WordPairComparison::theRank [private] | 
        
Definition at line 77 of file SimilarityMeasures.h.
 1.6.1