Six Reasons to Love Anaconda Python

Python is my go-to language for data wrangling, task automation and a whole range of other programming activities, and Anaconda from Continuum Analytics has been my Python distribution of choice for a number of years.

Here are six reasons why you should give it serious consideration if you are looking for a Python distribution.

1 Everything But The Kitchen Sink

Vanilla Python's standard library is useful, but for work in data science, web development and various other domains, additional packages are usually needed. For data science, in particular, installing these by hand can be a lengthy and tedious process, possibly involving compilation from source. As an added complication, this process can vary across different platforms.

With the full Anaconda distribution, you can avoid all of this hassle. It comes with the full SciPy ecosystem (NumPy, matplotlib, pandas, IPython, etc), plus packages for image processing, machine learning and many other things: in short, a complete environment for scientific computing. But it doesn't stop there. You can develop GUIs using PyQt, read and write Excel spreadsheets with Openpyxl, interact with web APIs using Kenneth Reitz's excellent Requests, build your own web applications with Flask, etc. Over 150 packages are included in the full installer, and many more can be easily added post-installation.

2 ...Or Start Small

A 'kitchen sink' distribution will cost you installation time and disk space, and may be overkill for your needs - in which case, a minimal Anaconda distribution called Miniconda is available. For Python 3.6 on 64-bit Linux, this is a 34 MB download, compared with over 470 MB for the full distribution! Once you've got your minimal install up and running, you can easily add just the packages you need using the conda management tool.

3 Clean Installation

It's isolated in its own directory, in your own filestore, and won't interfere with your system Python. On Linux and Mac, uninstalling is as simple as removing that directory, and possibly adjusting your PATH variable. (On Windows you can just uninstall in the normal way.) Removal shouldn't have any nasty side-effects.

4 Easy Management With conda

The conda management tool is the beating heart of Anaconda Python. It allows you to install, upgrade and remove packages, but it crucially also allows you to create, activate/deactivate and remove virtual environments. The two operations can even be combined. For example, the command

conda create -n mywebapp flask requests

will create a conda environment called mywebapp, containing the currently active version of Python, along with the Flask and Requests packages, and all their dependencies. (Dependencies will be downloaded unless they can be satisfied using the packages already installed 'globally' in Anaconda.) You can then activate this environment with

source activate mywebapp

and deactivate it with source deactivate.

Note that conda works alongside, rather than replacing, standard tools such as pip. You can use conda to add new packages to an environment by downloading from a configurable set of channels, but you can use pip instead if you prefer; in fact, you will have to do so if no version of the package is available in the Anaconda repositories. This flexibility and harmonious coexistence with the Python ecosystem is one of Anaconda's best features.

5 IDE Included

Many people will already have strong preferences for development tools when they start using Anaconda, but if you don't it is worth noting that the distribution includes a simple but useful IDE called Spyder. This integrates a Python code editor with Python & IPython intepreters and provides basic facilities for running and debugging code. One nice feature is a Variable Explorer panel that allows you to delve into data structures, exploring the values therein.

6 Actively Developed

Says it all, really. Packages in the repository are updated regularly, as are the downloadable distributions. And conda makes it easy to acquire those updates.


Comments powered by Disqus