Trouble installing TextBlob with pip

This is an error with the newest version of pip. If you have recently updated pip and are having this issue, here is what worked for me (based on https://github.com/pypa/pip/issues/7209): python -m pip uninstall pip curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py python get-pip.py –user python -m pip install –user textblob This uninstalls and reinstalls pip using –user.

nltk NaiveBayesClassifier training for sentiment analysis

You need to change your data structure. Here is your train list as it currently stands: >>> train = [(‘I love this sandwich.’, ‘pos’), (‘This is an amazing place!’, ‘pos’), (‘I feel very good about these beers.’, ‘pos’), (‘This is my best work.’, ‘pos’), (“What an awesome view”, ‘pos’), (‘I do not like this restaurant’, … Read more