Skip to content

Instantly share code, notes, and snippets.

@language-engineering
Created September 26, 2012 13:03
Show Gist options
  • Select an option

  • Save language-engineering/3787907 to your computer and use it in GitHub Desktop.

Select an option

Save language-engineering/3787907 to your computer and use it in GitHub Desktop.
from sussex_nltk.corpus_readers import TestCorpusReader #import the corpus reader
tcr = TestCorpusReader() #create a new corpus reader
tokens = tcr.words() #get the tokens of the corpus
for token in tokens: #iterate over the tokens
print token #print each token
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment