diff --git a/nltk-book/.gitignore b/nltk-book/.gitignore new file mode 100644 index 0000000..f7275bb --- /dev/null +++ b/nltk-book/.gitignore @@ -0,0 +1 @@ +venv/ diff --git a/nltk-book/chapter1.py b/nltk-book/chapter1.py new file mode 100644 index 0000000..8dd4a22 --- /dev/null +++ b/nltk-book/chapter1.py @@ -0,0 +1,8 @@ +import nltk + +f=open('my-file.txt','r') +raw=f.read() +tokens = nltk.word_tokenize(raw) +faceapp = nltk.Text(tokens) + +faceapp.concordance('you') \ No newline at end of file