Top "N-gram" questions

An N-gram is an ordered collection of N elements of the same kind, usually presented in a large collection of many other similar N-grams.

What algorithm I need to find n-grams?

What algorithm is used for finding ngrams? Supposing my input data is an array of words and the size of …

r n-gram
Finding ngrams in R and comparing ngrams across corpora

I'm getting started with the tm package in R, so please bear with me and apologies for the big ol' …

r text-mining n-gram tm
Get bigrams and trigrams in word2vec Gensim

I am currently using uni-grams in my word2vec model as follows. def review_to_sentences( review, tokenizer, remove_stopwords=…

python tokenize word2vec gensim n-gram
Quick implementation of character n-grams for word

I wrote the following code for computing character bigrams and the output is right below. My question is, how do …

python-2.7 n-gram
n-grams with Naive Bayes classifier

Im new to python and need help! i was practicing with python NLTK text classification. Here is the code example …

python nltk n-gram
Fast n-gram calculation

I'm using NLTK to search for n-grams in a corpus but it's taking a very long time in some cases. …

python nlp nltk n-gram
Filename search with ElasticSearch

I want to use ElasticSearch to search filenames (not the file's content). Therefore I need to find a part of …

lucene elasticsearch n-gram
NLTK package to estimate the (unigram) perplexity

I am trying to calculate the perplexity for the data I have. The code I am using is: import sys …

python-2.7 nlp nltk n-gram language-model
How to generate bi/tri-grams using spacy/nltk

The input text are always list of dish names where there are 1~3 adjectives and a noun Inputs thai iced tea …

python nlp nltk n-gram spacy
Ngram model and perplexity in NLTK

To put my question in context, I would like to train and test/compare several (neural) language models. In order …

python nltk n-gram