jaccardSimilarity method
Returns the Jaccard Similarity Index between this term and other
using a k
-gram length of k
.
The two strings are converted to lower-case and trimmed for the comparison.
Not case-sensitive.
Implementation
double jaccardSimilarity(String other, [int k = 2]) =>
_jaccardSimilarity(trim().toLowerCase().kGrams(k), other, k);