Conda cheat sheet

Conda is an open-source package and environment management system. It is primarily used to install multiple versions of software packages and their dependencies (e.g., Python and R) so that you can easily switch between them.

Cheat Sheet

Basics

Check the version number:

conda info

Update conda:

conda update conda

Install a package included in Anaconda:

conda install PACKAGE

Run a package:

PACKAGENAME

Update a package:

conda update PACKAGENAME

Help:

conda install --help

Environments

Create a new environment named py37 and install Python 3.7:

conda create --name py37 python=3.5 

Activate the new environment:

activate py37 (Windows)

Or:

source activate py37 (LINUX)

View all environments:

conda env list

List all packages and versions installed in the current active environment:

conda list

Delete an environment and everything in it:

conda env remove --name py37

Deactivate the current environment:

deactivate (Windows)
source deactivate (LINUX)

Searching

Search for a package:

conda search PACKAGENAME

Running the command above displays the associated information with the searched keywords.

Free Resources

Copyright ©2024 Educative, Inc. All rights reserved