From ba885cb4b88e7dcc8061e5faeb9e4f7c42644543 Mon Sep 17 00:00:00 2001 From: matthieugomez Date: Mon, 9 Nov 2015 08:59:25 -0500 Subject: [PATCH] compare --- README.md | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/README.md b/README.md index eca1890..f916f4f 100644 --- a/README.md +++ b/README.md @@ -26,18 +26,8 @@ Q-gram distances compare the set of all substrings of length `q` in each string. - [RatcliffObershelp Distance](https://xlinux.nist.gov/dads/HTML/ratcliffObershelp.html) ## Syntax -#### evaluate -The function `evaluate` returns the litteral *distance* between two strings (a value of 0 being identical). While some distances are bounded by 1, other distances like `Hamming`, `Levenshtein`, `Damerau-Levenshtein`, `Jaccard` can be higher than 1. -```julia -using StringDistances -evaluate(Hamming(), "martha", "marhta") -#> 2 -evaluate(QGram(2), "martha", "marhta") -#> 6 -``` -#### compare -The higher level function `compare` returns *a similarity score* between two strings. The similarity score is always between 0 and 1. A value of 0 being completely different and a value of 1 being completely similar. +The function `compare` returns *a similarity score* between two strings (based on the inverse of the distance). The similarity score is always between 0 and 1. A value of 0 being completely different and a value of 1 being completely similar. ```julia using StringDistances compare(Hamming(), "martha", "marhta")