cataloteca.LevenshteinDistance
1.0.0
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package cataloteca.LevenshteinDistance --version 1.0.0
NuGet\Install-Package cataloteca.LevenshteinDistance -Version 1.0.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="cataloteca.LevenshteinDistance" Version="1.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add cataloteca.LevenshteinDistance --version 1.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: cataloteca.LevenshteinDistance, 1.0.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install cataloteca.LevenshteinDistance as a Cake Addin #addin nuget:?package=cataloteca.LevenshteinDistance&version=1.0.0 // Install cataloteca.LevenshteinDistance as a Cake Tool #tool nuget:?package=cataloteca.LevenshteinDistance&version=1.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Cataloteca Algorithms
Library with machine learning algorithms from the 'cataloteca' project.
Levenshtein Distance
Algorithm used to calculate the distance and similarity between two strings.
How to use Levenshtein Distance Algorithm?
- Use Leveshtein project
using cataloteca.algorithms.LevenshteinDistance;
- Define your reference, ie the string you want to compare with your data.
string reference = "Example";
- Define your targets, ie the data you want to compare with the reference.
List<string> exampleList = new List<string>(new string[] {
"example 1",
"example 2",
"example 3"
});
- Use the method to calculate distance and similarity. By default the method returns the distance and similarity values, but you may not return one of the metrics
// Method that calculates string distance and similarity
var bothCalc = new LevenshteinInput(reference, exampleList);
var data = bothCalc.CallLevenstheinCalc(similarity:true, distance:true);
// Console Response Sample
// example
// -------------------
// example 1
// Distance: 2,00 | Similarity: 77,78%
// example 2
// Distance: 2,00 | Similarity: 77,78%
// example 3
// Distance: 2,00 | Similarity: 77,78%
- Use the method to calculate similarity only
// Method that calculates similarity only
var similarityCalc = new LevenshteinInput(reference, exampleList);
var data = similarityCalc.CallLevenstheinCalc(similarity:true, distance:false);
// Console Response Sample
// example
// -------------------
// example 1
// Similarity: 77,78%
// example 2
// Similarity: 77,78%
// example 3
// Similarity: 77,78%
- Use the method to calculate distance only
// Method that calculates only the distance
var distanceCalc = new LevenshteinInput(reference, exampleList);
var data = distanceCalc.CallLevenstheinCalc(similarity:false, distance:true);
// Console Response Sample
// example
// -------------------
// example 1
// Distance: 2,00
// example 2
// Distance: 2,00
// example 3
// Distance: 2,00
Author: Lucas Alves Siqueira
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp2.2 is compatible. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
.NETCoreApp 2.2
- DuoVia.FuzzyStrings (>= 2.0.1)
- Microsoft.ML (>= 1.3.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.