Reputation: 51
I have 2
anaconda in my system: one with python 2.7
& and another with python 3.5
.
My command prompt is showing python version as 2.7
.
I need to install one package for Python 3.5
using pip
only,not conda install. I installed it using pip. It's showing installed successfully, but I'm not able to import it in Anaconda with Python 3.5.
My python 2.7 path is given in path environmental variable. Can you suggest me how to install it using pip install for python 3.5
?
I don't have python 3 installed in my system. I think I have anaconda 3.5 environment in my system. Please refer the screen shot. Also I can't able to install python 3.5 in my system
Upvotes: 0
Views: 253
Reputation: 16583
Assuming you mean that you have two conda
environments, go to a Anaconda command prompt and activate the Python 3.5 environment. Then, if pip
is not installed, do:
conda install pip
Then, you should be able to run
pip install <package>
to install in to Python 3.5 provided that you are in the Python 3.5 environment.
If you don't have a Python 3.5 environment yet, simply do
conda create --name py35 python=3.5
followed by
activate py35 (Windows)
source activate py35 (Linux or macOS)
Upvotes: 1
Reputation: 541
You can use:
pip install --install-option="--prefix=$PATH_PREFIX" <package_name>
or
pip install -t <direct directory> <package_name>
Upvotes: 0
Reputation: 34046
To install a package in specific version, try this:
$ python-3.5 -m pip install <pkg-name>
Upvotes: 2