Reference

Class

RiTa

Name

RiTa.minEditDistance

Description Takes a pair of strings or string-arrays and returns the minimum edit distance between them (the number of additions, subtractions, or modifications it takes to go from one to the other)
Syntax
RiTa.minEditDistance(str1, str2);
Parameters
Stringstr1
Stringstr2
booleannormalize (optional) if true, normalizes the distance based on the length of the strings
Returns
intthe minimum-edit distance
Note See https://en.wikipedia.org/wiki/Edit_distance
Example

RiTa.minEditDistance("Hello", "Hell"); // -> 1

RiTa.minEditDistance("Hello", "Hell", true); // -> 0.2

Platform Java / Javascript