JSPM

cosine

0.0.1
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 22
  • Score
    100M100P100Q60059F
  • License

calculate the cosine distance between 2 arrays of strings

Package Exports

  • cosine

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (cosine) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

cosine

NPM version Build Status Dependency Status Coverage Status Code Climate

install

npm install [--save/--save-dev] cosine
component install cosine

api

var cosine = require('cosine')

var s1 = 'Julie loves me more than Linda loves me'.split(/\s/)
var s2 = 'Jane likes me more than Julie loves me or'.split(/\s/)

cosine(s1, s2) // => 0.7833494518006403

license

MIT