Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to install Statsmodels...python

I am using 32 bit cmd, 64 bit windows, python 2.7

when I type the command pip install statsmodels

I get the following error for some module of scipy...

Failed building wheel for Scipy Failed cleaning build dir for scipy

enter image description here

like image 336
Shank Avatar asked Aug 05 '16 14:08

Shank


2 Answers

install numpy

pip install numpy

If you face installation issues for numpy, get the pre-built windows installers from http://www.lfd.uci.edu/~gohlke/pythonlibs/ for your python version (python version is different from windows version).

numpy 32-bit: numpy-1.11.1+mkl-cp27-cp27m-win32.whl

numpy 64-bit: numpy-1.11.1+mkl-cp27-cp27m-win_amd64.whl

Later you require VC++ 9.0, then please get it from below link Microsoft Visual C++ 9.0 is required. Get it from http://aka.ms/vcpython27

Then install

Get the pre-built windows installers from http://www.lfd.uci.edu/~gohlke/pythonlibs/ for your python version (python version is different from windows version).

Scipy 32-bit: scipy-0.18.0-cp27-cp27m-win32.whl

Scipy 64-bit: scipy-0.18.0-cp27-cp27m-win_amd64.whl

If it fails saying whl is not supported wheel on this platform , then upgrade pip using python -m pip install --upgrade pip and try installing scipy

Now try

pip install scipy

Then try

pip install statsmodels

It should work like a charm

like image 118
be_good_do_good Avatar answered Oct 05 '22 23:10

be_good_do_good


I have tried to write this on cmd.exe and it worked.

pip install statsmodels==0.6.0

install statsmodels for python 2.7 in windows

like image 43
Minh Chau Huynh Avatar answered Oct 06 '22 00:10

Minh Chau Huynh