Skip to main content

Different distances for Python

Project description

distans

Different distances for Python

Install

pip install distans

Usage

Lp distance

from distans import lp

a = [1, -2, 3]
b = [3, 4, -5]

p = 2
norm = lp(a, p=p)
dist = lp(a, b, p=p)

Edit similarity

from distans import jaro_sim, jaro_winkler_sim

jaro_sim('hello', 'helo')
jaro_winkler_sim('hi', 'hey')

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

distans-0.1.6.tar.gz (6.4 kB view hashes)

Uploaded Source

Built Distribution

distans-0.1.6-py3-none-any.whl (7.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page