Anaconda is an open-source distribution of R and Python-based programming languages. It handles scientific computing in data science and Machine learning (ML). It comprises all the necessary tools that are required for scientific work and large data analysis.
Anaconda distribution includes several packages such as Spyder, Jupyter, Tensor flow, Numpy, etc. It is suitable for desktop operating systems like Mac, Windows, Linux, etc. This descriptive article will provide you with enhanced knowledge to install Anaconda in Ubuntu 22.04.
How to Install Anaconda in Ubuntu 22.04?
Ubuntu does not have Anaconda packages as default packages. However, it can be installed in Ubuntu 22.04 using the Anaconda installer script. Therefore, to go with this purpose, follow the below-mentioned guide one by one:
Step 1: Update System packages list
To attain the latest/updated packages, update the system’s default repository by executing the below script:
$ sudo apt update
The installed packages of the system are updated.
Step 2: Install Curl
Curl allows you to fetch the Anaconda installation script. Install Curl on Ubuntu 2204 by running the following command:
$ sudo apt install curl
The Curl was installed successfully.
Step 3: Download the bash script for the Anaconda installer
To download the Anaconda installer script, run the below-mentioned command:
$ curl --output anaconda.sh https://repo.anaconda.com/archive/Anaconda3-5.3.1-Linux-x86_64.sh
The Anaconda installer script has been downloaded.
Step 4: Verify data integrity
To check whether the Anaconda installer Script is downloaded from the official site or not, run the following command:
$ sha256sum anaconda.sh
The data integrity is verified.
Step 5: Install Anaconda in Ubuntu 22.04
Bash, known as Bourne Again Shell, which incorporates valuable features. To install Anaconda on Ubuntu 22.04, run the anaconda.sh script as follows:
$ bash anaconda.sh
Anaconda directory is created inside our home directory:
The “bashrc” is initialized for anaconda.
After the license agreement and terms, the Anaconda is installed successfully in Ubuntu 22.04.
Step 6: Activate the Anaconda environment
As the bashrc script for Anaconda has already been initialized (Step 4, where the Anaconda’s script was executed). You can execute the bashrc script to activate the Anaconda environment as follows:
$ source ~/.bashrc
The Anaconda environment has been activated successfully.
Step 7: Verify installation
To verify the Anaconda installation, get the version of Anaconda via the following command:
$ conda --version
The Anaconda version 4.5.11 is installed on Ubuntu 22.04.
How to Remove Anaconda From Ubuntu 22.04
If you have installed Anaconda in Ubuntu 22.04 using the terminal, you can remove/uninstall it with the help of the following command:
$ rm -rf ~/anaconda3
The “rm -rf” command is used to remove/uninstall all the files forcibly. This command has removed the anaconda3 directory from the home directory.
Congratulations! You have experienced the installation of Anaconda in Ubuntu 22.04.
Anaconda can be installed in Ubuntu 22.04 by downloading and executing the bash script of Anaconda. Anaconda distribution is used to handle scientific computing in data science and machine learning. It comprises all the necessary tools that are required for scientific work and large data analysis. This descriptive write-up has illustrated the installation method of Anaconda in Ubuntu 22.04 through the terminal by using the Anaconda installer script.