


% -*- texinfo -*-
% @deftypefn {Function File} [@var{dist},@var{L}] = {} editdistance(@var{string1},@var{string2},@var{weights})
% computes the Levenshtein edit distance between the two strings.
% @var{string1} and @var{string2}. This operation is symmetrical.
% The optional argument @var{weights} specifies weights for the
% deletion, matched, and insertion operations; by default it is set to
% +1, 0, +1 respectively, so that a least editdistance means a 
% closer match between the two strings. This function implements
% the Levenshtein edit distance as presented in Wikipedia article,
% accessed Nov 2006. Also the levenshtein edit distance of a string
% with an empty string is defined to be its length.
% 
% The default return value is @var{dist} the edit distance, and
% the other return value  @var{L} is the distance matrix.
%
% @example
% @group  
%          editdistance('marry','marie') 
%          %%returns value +2 for the distance.
% @end group
% @end example
%
% @end deftypefn
%