0.0.1 • Published 10 years ago

nltk v0.0.1

Weekly downloads
17
License
MIT
Repository
github
Last release
10 years ago

nltk

n-gram

coffee> nltk = require 'nltk'
{ ngram: [Function: ngram] }
coffee> nltk.ngram
[Function: ngram]
coffee> nltk.ngram 3
undefined
coffee> new nltk.ngram 3
{ enum: [Function], sim: [Function] }
coffee> Tri = new nltk.ngram 3
{ enum: [Function], sim: [Function] }
coffee> Tri.enum 'ABCDEFG'
[ 'ABC', 'BCD', 'CDE', 'DEF', 'EFG' ]
coffee> Tri.sim 'ABCDEFG', 'EFGABC'
0.4472135954999579