Can someone tell me the difference between a Corpora ,corpus and lexicon in NLTK ?
What is the movie data set ?
what is Wordnet ?
Can someone tell me the difference between a Corpora ,corpus and lexicon in NLTK ?
What is the movie data set ?
what is Wordnet ?
Corpora is the plural for corpus.
Corpus basically means a body, and in the context of Natural Language Processing (NLP), it means a body of text.
(source: https://www.google.com.sg/search?q=corpora)
Lexicon is a vocabulary, a list of words, a dictionary (source: https://www.google.com.sg/search?q=lexicon)
In NLTK, any lexicon is considered a corpus since a list of words is also a body of text. E.g. a list of stopwords can be found in NLTK corpus API:
The movie review dataset in NLTK (canonically known as
Movie Reviews Corpus
) is a text dataset of 2k movie reviews with sentiment polarity classification (source: http://www.nltk.org/book/ch02.html)And it is often used for tutorial purposes for introduction to NLP and sentiment analysis, see http://www.nltk.org/book/ch06.html and nltk NaiveBayesClassifier training for sentiment analysis
WordNet is lexical database for the English language (it's like a lexicon/dictionary with word-to-word relations) (source: https://wordnet.princeton.edu/).
In NLTK, it incorporates the Open Multilingual WordNet (http://compling.hss.ntu.edu.sg/omw/) that allows you to query the words in other languages.
Since it is also a list of words (in this case with many other things included, relations, lemmas, POS, etc.), it's also invoked using
nltk.corpus
in NLTK.The canonical idiom to use the wordnet in NLTK is as such:
The easiest way to understand/learn the NLP jargons and the basics is to go through these tutorial in the NLTK book: http://www.nltk.org/book/