I have a MacBook Pro that came pre-installed with python2.7
. I later installed python3
and ipython
notebook. I installed pip
too to install packages, and am able to install packages and run program from python3
. However, for another project I need to run code in python2.7
, and I am not sure how to install it in python2.7
folder.
I tried using pip for installing packages to 2.7, but it kept giving error saying package already exists. When I check for version of python using --version
, I see 2 pythons installed. However, when I check for pip
and pip3
, both seem to be in th same folder.
Any tips on how to install packages in python2.7
, without making any changes to 3.3? I am using python3 and ipython
notebooks for another project.
viveks-mbp:~ vivekyadav$ which pip
/Library/Frameworks/Python.framework/Versions/3.3/bin/pip
viveks-mbp:~ vivekyadav$ which pip3
/Library/Frameworks/Python.framework/Versions/3.3/bin/pip3
viveks-mbp:~ vivekyadav$ which python
/usr/bin/python
viveks-mbp:~ vivekyadav$ which python3
/Library/Frameworks/Python.framework/Versions/3.3/bin/python3