Installing anaconda over existing python system?

anjchang picture anjchang · Jan 20, 2016 · Viewed 33.2k times · Source

I found an old windows xp machine running Python 2.5.2. I would like to use Anaconda instead. Can I just install Anaconda on it and do I have to uninstall Python 2.5.2? Similarly, I have a Mac system with Python 2.7.9 working with some NLT libraries and I'd like to get Anaconda running on it too. What's the best course of action to get Anaconda over an existing system that already has python?

Answer

Dimitris Fasarakis Hilliard picture Dimitris Fasarakis Hilliard · Jan 20, 2016

Simply install.

Anaconda manages Python for you and creates the appropriate bin directory containing the executable and pkgs directory containing installed packages. All this in a directory structure named anaconda (or anaconda3 if using Python 3). Additionally, it alters the search path so the Python inside the anaconda/bin/ directory is the one used when the command python is issued.

On Ubuntu, it looks like this:

# added by Anaconda 2.3.0 installer
export PATH="/home/jim/anaconda/bin:$PATH"

By adding the new path in the beginning of PATH it assures the anaconda bin/python will be located first.

Warning:

do I have to uninstall Python 2.5.2?

In general never remove the 'original' Python unless explicitly allowed by official sources. In many operating systems Python is a dependency; it must stay around. I can't speak for old versions of Windows but in general if you're not sure if it is needed or not leave it.

Removing it might break some completely unrelated things.