public static StringDistanceResult MeasureDistance(this AbstractStringMetric metric, string a, string b) { return(new StringDistanceResult { Similarity = metric.GetSimilarity(a, b), UnnormalizedSimilarity = metric.GetUnnormalisedSimilarity(a, b), MetricAlgorithm = metric, SimilarityDescription = metric.GetSimilarityExplained(a, b), ShortDescription = metric.ShortDescriptionString, LongDescription = metric.LongDescriptionString }); }
/// <summary> /// constructor taking metric to use /// </summary> /// <param name="metricToUse">the string metric to use</param> public MongeElkan(AbstractStringMetric metricToUse) { tokeniser = new TokeniserWhitespace(); internalStringMetric = metricToUse; }
/// <summary> /// constructor taking a tokeniser and string metric to use /// </summary> /// <param name="tokeniserToUse">the tokeniser to use should a different tokeniser be required</param> /// <param name="metricToUse">the string metric to use</param> public MongeElkan(ITokeniser tokeniserToUse, AbstractStringMetric metricToUse) { tokeniser = tokeniserToUse; internalStringMetric = metricToUse; }
public MongeElkan(ITokeniser tokeniserToUse, AbstractStringMetric metricToUse) { this.estimatedTimingConstant = 0.034400001168251038; this.tokeniser = tokeniserToUse; this.internalStringMetric = metricToUse; }
public MongeElkan(ITokeniser tokeniserToUse) { this.estimatedTimingConstant = 0.034400001168251038; this.tokeniser = tokeniserToUse; this.internalStringMetric = new SmithWatermanGotoh(); }
public MongeElkan(AbstractStringMetric metricToUse) { this.estimatedTimingConstant = 0.034400001168251038; this.tokeniser = new TokeniserWhitespace(); this.internalStringMetric = metricToUse; }