Use Julia from Jupyter notebook

less than 1 minute read

Related: Install Julia IDE: Juno


IJulia allows running Julia from within the web browser-based Jupyter IDE.

1. Install Julia

In general (for all operating systems) it’s recommended to use the downloads from Julia website.

2. Install Jupyter

Locate Jupyter binary location

which jupyter

If it’s not installed, just do

conda install jupyter

3. Install IJulia

  1. start Julia with this environment variable (only necessary once)
    JUPYTER=~/miniconda3/bin/jupyter julia
    
  2. type at Julia prompt:
    Pkg.add("IJulia")
       
    Pkg.build("IJulia")
    

    This installs numerous packages via conda automatically.

Usage

  1. start the Notebook either by:

    • Terminal/Command Prompt: jupyter notebook
    • Julia: using IJulia; notebook()
  2. Create an interactive Julia .ipynb Julia notebook by clicking New → Julia. Existing .jl files are NOT runnable from IJulia.

Notes

Tags:

Categories:

Updated:

Leave a Comment