I recently started working with Ubuntu and got stuck with a problem. I downloaded Anaconda version 3.4 for Linux and installed it using the command :
bash ./Anaconda3-4.3.1-Linux-x86_64.sh
when I run the command python --version or python3 --version I get this result:

Python 2.7.12+
Python 3.5.2+

which has to be Python 2.7.12 :: Continum Analytics inc.

It is probably because Ubuntu has python 2.7 and python 3.4 installed by default.

What can I do to get access to python with anaconda libraries?


You have to add anaconda path to your .bashrc file like this:

# added by Anaconda2 4.2.0 installer
export PATH="/home/george/anaconda2/bin:$PATH"

Why your installer didn't add it is another issue, but source your .bashrc file just to be sure, or better still look in there if not there then add the line above and source it to make it take effect.

| improve this answer | |
  • Was it there already or you had to enter it manually? – George Udosen Mar 17 '17 at 16:32
  • If this resolved your issue, please accept the answer! Also, consider using virtual environments, you can use anaconda to manage multiple conda envs, virtualenv (by itself or in combo with virtualenvwrapper) or venv (this one comes with Python from 3.4 onward). – Samuel Mar 19 '17 at 3:50

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.