Relationship With Other Edit Distance Metrics
Levenshtein distance is not the only popular notion of edit distance. Variations can be obtained by changing the set of allowable edit operations: for instance,
- length of the longest common subsequence is the metric obtained by allowing only addition and deletion, not substitution;
- the Damerau–Levenshtein distance allows addition, deletion, substitution, and the transposition of two adjacent characters;
- the Hamming distance only allows substitution (and hence, only applies to strings of the same length).
Edit distance in general is usually defined as a parametrizable metric in which a repertoire of edit operations is available, and each operation is assigned a cost (possibly infinite). This is further generalized by DNA sequence alignment algorithms such as the Smith–Waterman algorithm, which make an operation's cost depend on where it is applied.
Read more about this topic: Levenshtein Distance
Famous quotes containing the words relationship, edit and/or distance:
“Only men of moral and mental force, of a patriotic regard for the relationship of the two races, can be of real service as ministers in the South. Less theology and more of human brotherhood, less declamation and more common sense and love for truth, must be the qualifications of the new ministry that shall yet save the race from the evils of false teaching.”
—Fannie Barrier Williams (18551944)
“To a philosopher all news, as it is called, is gossip, and they who edit it and read it are old women over their tea.”
—Henry David Thoreau (18171862)
“The rage for road building is beneficent for America, where vast distance is so main a consideration in our domestic politics and trade, inasmuch as the great political promise of the invention is to hold the Union staunch, whose days already seem numbered by the mere inconvenience of transporting representatives, judges and officers across such tedious distances of land and water.”
—Ralph Waldo Emerson (18031882)