I’ve released the Levenshtein module as a gem. The most
expensive part of the algorithm is written in C. But before
entering the most expensive part of the algorithm, it tries to
optimize as much as possible (in Ruby land).
There’s a TAR.GZ archive and a GEM for Linux (tested), OS X
(untested) and Cygwin (tested). I wasn’t able to compile a
version that worked with the One-Click Ruby Installer. I’m not
familiar with Windows, nor with its development environment.
Anyone willing to help?
gegroet,
Erik V. - http://www.erikveen.dds.nl/
The Levenshtein distance is a metric for measuring the amount
of difference between two sequences (i.e., the so called edit
distance). The Levenshtein distance between two strings is
given by the minimum number of operations needed to transform
one string into the other, where an operation is an insertion,
deletion, or substitution of a single character.
More information about the Levenshtein distance algorithm:
Levenshtein distance - Wikipedia .
More information about the library:
levenshtein (0.2.2) .