Skip to content
EntityQ94489· pop 25· linked from 202 articles

Also known as n-grams, ngrams, ngram, n gram, n grams

An '''n-gram' is a sequence of n adjacent symbols in a particular order. The symbols may be n'' adjacent letters (including punctuation marks and blanks), syllables, or rarely whole words found in a language dataset; or adjacent phonemes extracted from a speech-recording dataset, or adjacent base pairs extracted from a genome. They are collected from a text corpus or speech corpus.

In the Vinony graph

Within Vinony's link graph, n-gram is referenced by 202 other articles, and connects out to numeral prefix, Google Ngram Viewer and word.

It is catalogued under topics including Computational linguistics, Corpus linguistics and Language modeling.

Its subject is documented across 25 Wikipedia language editions.

Wikidata facts

Subclass of
string
Show 1 more fact
Sources (3)

via Wikidata · CC0

~4 min read

Encyclopedic overview

5 sections
Contents
  • Examples
  • References
  • Further reading
  • See also
  • External links

An '''n-gram' is a sequence of n adjacent symbols in a particular order. The symbols may be n adjacent letters (including punctuation marks and blanks), syllables, or rarely whole words found in a language dataset; or adjacent phonemes extracted from a speech-recording dataset, or adjacent base pairs extracted from a genome. They are collected from a text corpus or speech corpus.

If Latin numerical prefixes are used, then n-gram of size 1 is called a "unigram", size 2 a "bigram" (or, less commonly, a "digram") etc. If, instead of the Latin ones, the English cardinal numbers are furtherly used, then they are called "four-gram", "five-gram", etc. Similarly, Greek numerical prefixes such as "monomer", "dimer", "trimer", "tetramer", "pentamer", etc., or English cardinal numbers, "one-mer", "two-mer", "three-mer", etc. are used in computational biology for polymers or oligomers of a known size, called k-mers. When the items are words, -grams may also be called shingles.

Excerpted from Wikipedia’s “n-gram” article, available under the CC BY-SA 4.0 licence.

Categories