C# Класс Spontaneuos.Lib.SiftStringSimilarity.StringMetrics

Helper class for Sift3, Levenstein and length distance and similarities
Показать файл Открыть проект

Открытые методы

Метод Описание
FastDistance ( string s1, string s2, int maxDistance ) : float

Fast compute the distance between two strings based on several levels of accuracy First length, then Sift, then Levenstein

FastSimilarity ( string s1, string s2, float minSimilarity ) : float

Fast compute the similarity between two strings based on several levels of accuracy First length, then Sift, then Levenstein

LengthDistance ( string s1, string s2 ) : int

Calculate the distance between two strings by length alone

LengthSimilarity ( string string1, string string2 ) : float

Calculate the similarity between two strings by length alone

LevensteinDistance ( string s, string t ) : int

Calculate the Levenstein string distance

LevensteinSimilarity ( string string1, string string2 ) : float

Calculate the percentage of Levenstein similarity between two strings

SiftDistance ( string s1, string s2 ) : float

Calculate the Sift3 distance between 2 strings

SiftSimilarity ( string s1, string s2 ) : float

Calculate the Sift3 similarity between 2 strings

Описание методов

FastDistance() публичный статический Метод

Fast compute the distance between two strings based on several levels of accuracy First length, then Sift, then Levenstein
public static FastDistance ( string s1, string s2, int maxDistance ) : float
s1 string
s2 string
maxDistance int
Результат float

FastSimilarity() публичный статический Метод

Fast compute the similarity between two strings based on several levels of accuracy First length, then Sift, then Levenstein
public static FastSimilarity ( string s1, string s2, float minSimilarity ) : float
s1 string
s2 string
minSimilarity float
Результат float

LengthDistance() публичный статический Метод

Calculate the distance between two strings by length alone
public static LengthDistance ( string s1, string s2 ) : int
s1 string
s2 string
Результат int

LengthSimilarity() публичный статический Метод

Calculate the similarity between two strings by length alone
public static LengthSimilarity ( string string1, string string2 ) : float
string1 string
string2 string
Результат float

LevensteinDistance() публичный статический Метод

Calculate the Levenstein string distance
public static LevensteinDistance ( string s, string t ) : int
s string first string
t string second string
Результат int

LevensteinSimilarity() публичный статический Метод

Calculate the percentage of Levenstein similarity between two strings
public static LevensteinSimilarity ( string string1, string string2 ) : float
string1 string first string
string2 string second string
Результат float

SiftDistance() публичный статический Метод

Calculate the Sift3 distance between 2 strings
public static SiftDistance ( string s1, string s2 ) : float
s1 string
s2 string
Результат float

SiftSimilarity() публичный статический Метод

Calculate the Sift3 similarity between 2 strings
public static SiftSimilarity ( string s1, string s2 ) : float
s1 string
s2 string
Результат float