levenshtein_distance
A string comparison function to estimate the similarity between two strings. The result of this function is the number of edit operations (insertions, deletions, or modifications) to convert one string into another. A full description of the Levenshtein distance function can be found here.
Returns: Integer
Table 1.
Parameter | Type |
---|---|
x | string |
y | string |
Example
Query
PREFIX : <https://ddw-doccorp.linked.data.world/d/sparql-function-sample-queries/> PREFIX fn: <http://data.world/function/functions#> SELECT (fn:levenshtein_distance("foobar", "boofar") AS ?levenshtein_distance) { }
Table 2. Results
levenshtein_distance |
---|
2 |