Open In App

How to Install Julia in an anaconda environment?

Julia is a high-level open-source programming language, developed by MIT. It is a dynamic, high-performance programming language that is used to perform operations in scientific computing. Anaconda is a free and open-source distribution of the programming languages Python and R programming languages for scientific computing, data processing, and data analytics. It includes Jupyter, Spyder, and a powerful CLI to manage the development environment. Let’s discuss how to install Julia programming language in an anaconda environment.

Installation of Julia in an anaconda environment

Step 1: Click here to download the latest version of Anaconda. 



 

Step 2: Next, install Anaconda 

$ bash Anaconda3-2022.05-Linux-x86_64.sh



 

 

 

Step 3: Verify the installation.

$ conda –version

 

Step 4: Create and activate a new environment by using conda cli.

$ conda create -n <env-name>

$ conda activate <env-name>

 

 

Step 5: Finally, install Julia from the conda-forge channel.

$ conda install -c conda-forge julia

 

 

 

Step 6: Finally, verify the installation by opening Julia REPL

 

Compiling Julia files

We can also compile Julia files using julia-cli. For now, I have created a very basic julia file that outputs “Geeks for Geeks”.




print("Geeks For Geeks")

Now, compile the file

$ julia filename.jl

 

Using IJulia on Jupyter Notebook

We can also use Julia with Jupyter Notebook by installing the IJulia package.

Step 1: Open the Julia REPL 

$ julia

Step 2: Install IJulia package from Julia CLI

> using Pkg

> Pkg.add(“IJulia”)

 

 

Step 3: Open Jupyter Notebook

 $ jupyter notebook

 

Step 4: Click on “New” on the top right corner and create a new notebook.

 

 

Article Tags :