1

I know how to install external modules using the pip command but for Scikit-learn I need to install NumPy and Matplotlib as well.

How can I install these modules using the pip command?

Jonathan Porter
  • 1,365
  • 7
  • 34
  • 62
  • This is a common problem and there are tons of answer on the web. Just google `install scikit-learn windows` – cel Aug 17 '16 at 06:51
  • There is a Python distribution named Anakonda, where the installation of these packages is easier. http://stackoverflow.com/questions/27045176/problems-with-installing-and-using-scikit-learn-in-anaconda – John Donn Aug 17 '16 at 07:00
  • 2
    If you are on Windows, my advice is to use the [Anaconda Python distribution](https://www.continuum.io/downloads#_windows). – juanpa.arrivillaga Aug 17 '16 at 07:00
  • @Rajesh You should view [this example](https://eatsleepdata.com/blogs/machine-learning/how-to-install-python-machine-learning-packages-using-anaconda) of how to properly install Scikit-learn using Anaconda. – Jonathan Porter May 13 '17 at 17:21

2 Answers2

0

Old post, but right answer is, 'sudo pip install -U numpy matplotlib --upgrade' for python2 or 'sudo pip3 install -U numpy matplotlib --upgrade' for python3

-1

Using Python 3.4, I run the following from the command line:

c:\python34\python.exe -m pip install package_name

So you would substitute "numpy" and "matplotlib" for 'package_name'

Yakir
  • 1
  • 1