Search code examples
algorithmlevenshtein-distanceedit-distance

Variation of Edit distance algorithm that only tracks substitutions and insertions


Does anyone know of edit-distance algorithm that only counts substitutions and insertions. So basically, it would be Levenshtein Distance algorithm without deletions.


Solution

  • You can use almost the same dynamic programming solution that is used for computing normal Levenshtein distance, but without transitions that correspond to deletions.