Spatium
Spatium -- library for comparing distance between sequences.
Algorithms
Edit based
Example
For example, Levenshtein:
use levenshtein;
// Get default algorithm for calc levenshtein distance.
let alg = default;
let x = ;
let y = ;
let distance = alg.distance.unwrap;
assert_eq!;
// With normaliztion (normalized distance = distance / x.len())
let alg = default.normalize_result;
let x = ;
let y = ;
let distance = alg.distance.unwrap;
assert_eq!;
// Use obviously algorithm (for example recursive version)
let alg = default;
let x = ;
let y = ;
let distance = alg.distance.unwrap;
assert_eq!;
License
Spatium is distributed under the terms of both the MIT license and the Apache License (Version 2.0).
See LICENSE-APACHE and LICENSE-MIT for details.