| 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.wcohen.ss.AbstractStringDistance
com.wcohen.ss.WinklerRescorer
public class WinklerRescorer
Winkler's reweighting scheme for distance metrics. In the literature, this was applied to the Jaro metric ('An Application of the Fellegi-Sunter Model of Record Linkage to the 1990 U.S. Decennial Census' by William E. Winkler and Yves Thibaudeau.)
| Constructor Summary | |
|---|---|
WinklerRescorer(StringDistance innerDistance)
Rescore the innerDistance's scores, to account for the subjectively greater importance of the first few characters.  | 
|
| Method Summary | |
|---|---|
 java.lang.String | 
explainScore(StringWrapper s,
             StringWrapper t)
This method needs to be implemented by subclasses.  | 
 StringWrapper | 
prepare(java.lang.String s)
Default way to preprocess a string for distance computation.  | 
 double | 
score(StringWrapper s,
      StringWrapper t)
This method needs to be implemented by subclasses.  | 
 java.lang.String | 
toString()
 | 
| Methods inherited from class com.wcohen.ss.AbstractStringDistance | 
|---|
addExample, doMain, explainScore, getDistance, hasNextQuery, nextQuery, prepare, prepare, score, setDistanceInstancePool, setStringWrapperPool | 
| Methods inherited from class java.lang.Object | 
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Constructor Detail | 
|---|
public WinklerRescorer(StringDistance innerDistance)
Note: the innerDistance must produce scores between 0 and 1.
| Method Detail | 
|---|
public java.lang.String toString()
toString in class java.lang.Object
public double score(StringWrapper s,
                    StringWrapper t)
AbstractStringDistance
score in interface StringDistancescore in class AbstractStringDistance
public java.lang.String explainScore(StringWrapper s,
                                     StringWrapper t)
AbstractStringDistance
explainScore in interface StringDistanceexplainScore in class AbstractStringDistancepublic StringWrapper prepare(java.lang.String s)
AbstractStringDistance
prepare in interface StringDistanceprepare in class AbstractStringDistance
  | 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||