@hackage edit-distance0.2.2.1
Levenshtein and restricted Damerau-Levenshtein edit distances
Categories
License
BSD-3-Clause
Maintainer
Oleg Grenrus <oleg.grenrus@iki.fi>
Links
Versions
Installation
Dependencies (4)
- array >=0.1
- base >=4.5 && <5
- containers >=0.1.0.1
- random >=1.0 Show all…
Dependents (30)
@hackage/git-annex, @hackage/pencil, @hackage/RNAlien, @hackage/ms, @hackage/psc-ide, @hackage/Agda, Show all…
Edit Distance Algorithms
Installing
To just install the library:
cabal configure
cabal build
cabal install
Description
Edit distances algorithms for fuzzy matching. Specifically, this library provides:
They have been fairly heavily optimized. Indeed, for situations where one of the strings is under 64 characters long we use a rather neat "bit vector" algorithm: see the authors paper and the associated errata for more information. The algorithms could be faster, but they aren't yet slow enough to force us into improving the situation.
Example
Text.EditDistance> levenshteinDistance defaultEditCosts "witch" "kitsch"
2