Update 4_1_Lexical_Processing.ipynb

dveni-patch-2
Dani Vera 4 years ago committed by GitHub
parent e70689072f
commit 19ea5dff09
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -326,7 +326,7 @@
"def preprocess(words, type='doc'):\n",
" if (type == 'tweet'):\n",
" tknzr = TweetTokenizer(strip_handles=True, reduce_len=True)\n",
" tokens = tknzr.tokenize(tweet)\n",
" tokens = tknzr.tokenize(words)\n",
" else:\n",
" tokens = nltk.word_tokenize(words.lower())\n",
" porter = nltk.PorterStemmer()\n",

Loading…
Cancel
Save