Mac 10.13.4

Trying to install NLTK (http://www.nltk.org/install.html)

Using command sudo pip install -U nltk as stated in the above resource.

Returns sudo: pip: command not found

What does this mean in this instance?

Why would I not use sudo apt-get install python-nltk?

Return for which -a python python3 shows /usr/bin/python /Library/Frameworks/Python.framework/Versions/3.6/bin/python3 /usr/local/bin/python3

Is it because I'm running 3.6 and req is 3.5? The resources notes for older versions you may have to do setuptools and pip but... something seems off to me because I have an updated Macos.

  • Pip was not installed on python 3.6. Perhaps the documentation should reflect that 3.6 (from python.org) needs separate pip. – Gryph May 4 '18 at 15:26
  • pip is bundled with python3.6, you just need to call it via python3.6 -m pip install somepkg. – hoefling May 5 '18 at 10:17
  • If you want to have a separate installation of pip (the pre-3.4 way), run sudo easy_install3 pip (referring to this question on SO). – hoefling May 5 '18 at 10:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.