/** Version of distance which is possibly scaled to [0,1]. */ public double score(StringWrapper s,StringWrapper t) { if (scaling) { int minLen = Math.min( s.unwrap().length(), t.unwrap().length() ); return super.score(s,t) / (minLen * CHAR_EXACT_MATCH_SCORE); } else { return super.score(s,t); } } /** Version where distance which is possibly scaled to [0,1]. */
/** Version of distance which is possibly scaled to [0,1]. */ public double score(StringWrapper s,StringWrapper t) { if (scaling) { int minLen = Math.min( s.unwrap().length(), t.unwrap().length() ); return super.score(s,t) / (minLen * CHAR_EXACT_MATCH_SCORE); } else { return super.score(s,t); } } /** Version where distance which is possibly scaled to [0,1]. */
/** Version of distance which is possibly scaled to [0,1]. */ public double score(StringWrapper s,StringWrapper t) { if (scaling) { int minLen = Math.min( s.unwrap().length(), t.unwrap().length() ); return super.score(s,t) / (minLen * CHAR_EXACT_MATCH_SCORE); } else { return super.score(s,t); } } /** Version where distance which is possibly scaled to [0,1]. */
public double score(StringWrapper s,StringWrapper t) { MatrixTrio mat = new MatrixTrio( s, t ); return score(s,t,mat); }
public double score(StringWrapper s,StringWrapper t) { MatrixTrio mat = new MatrixTrio( s, t ); return score(s,t,mat); }
public double score(StringWrapper s,StringWrapper t) { MatrixTrio mat = new MatrixTrio( s, t ); return score(s,t,mat); }
public String explainScore(StringWrapper s,StringWrapper t) { MatrixTrio mat = new MatrixTrio( s, t ); double d = score(s,t,mat); return mat.toString() + "\nScore = "+d; }
public String explainScore(StringWrapper s,StringWrapper t) { MatrixTrio mat = new MatrixTrio( s, t ); double d = score(s,t,mat); return mat.toString() + "\nScore = "+d; }
public String explainScore(StringWrapper s,StringWrapper t) { MatrixTrio mat = new MatrixTrio( s, t ); double d = score(s,t,mat); return mat.toString() + "\nScore = "+d; }
/** Version where distance which is possibly scaled to [0,1]. */ public String explainScore(StringWrapper s,StringWrapper t) { if (scaling) { int minLen = Math.min( s.unwrap().length(), t.unwrap().length() ); double scaledDist = super.score(s,t) / (minLen * CHAR_EXACT_MATCH_SCORE); return super.explainScore(s,t) + "\nScaling factor: "+(minLen*CHAR_EXACT_MATCH_SCORE) + "\nScaled score: "+scaledDist; } else { return super.explainScore(s,t); } }
/** Version where distance which is possibly scaled to [0,1]. */ public String explainScore(StringWrapper s,StringWrapper t) { if (scaling) { int minLen = Math.min( s.unwrap().length(), t.unwrap().length() ); double scaledDist = super.score(s,t) / (minLen * CHAR_EXACT_MATCH_SCORE); return super.explainScore(s,t) + "\nScaling factor: "+(minLen*CHAR_EXACT_MATCH_SCORE) + "\nScaled score: "+scaledDist; } else { return super.explainScore(s,t); } }
/** Version where distance which is possibly scaled to [0,1]. */ public String explainScore(StringWrapper s,StringWrapper t) { if (scaling) { int minLen = Math.min( s.unwrap().length(), t.unwrap().length() ); double scaledDist = super.score(s,t) / (minLen * CHAR_EXACT_MATCH_SCORE); return super.explainScore(s,t) + "\nScaling factor: "+(minLen*CHAR_EXACT_MATCH_SCORE) + "\nScaled score: "+scaledDist; } else { return super.explainScore(s,t); } }