Package nltk :: Module text
[hide private]
[frames] | no frames]

Module text

source code

This module brings together a variety of NLTK functionality for text analysis, and provides simple, interactive interfaces. Functionality includes: concordancing, collocation discovery, regular expression search over tokenized strings, and distributional similarity.

Classes [hide private]
ContextIndex
A bidirectional index between words and their 'contexts' in a text.
ConcordanceIndex
An index that can be used to look up the offset locations at which a given word occurs in a document.
TokenSearcher
A class that makes it easier to use regular expressions to search over tokenized strings.
Text
A wrapper around a sequence of simple (string) tokens, which is intended to support initial exploration of texts (via the interactive console).
TextCollection
A collection of texts, which can be loaded with list of texts, or with a corpus consisting of one or more texts, and which supports counting, concordancing, collocation discovery, etc.
Functions [hide private]
 
demo() source code