Table of Contents
This is an intensive full-day workshop for the Julia language, composed out of three 2-hour segments. It assumes only rudimentary programming familiarity. The goal of the workshop is to take you from zero to hero (regarding Julia): even if you know nothing about Julia, by the end you should be able to use it like a pro.
The material has been updated during July-August 2023 to Julia v1.9+ and corresponding latest stable versions of used packages.
This workshop is also available on YouTube: https://www.youtube.com/watch?v=Fi7Pf2NveH0 (in its original form)
Installing Julia and the environment you want to program in Julia is NOT part of this workshop! There are many options, up to preference, and may even depend on your operating system.
We recommend to install Julia using the most automated, pre-packaged, and fool-proof way, which is as follows:
- Install Julia via
juliaup
: https://github.com/JuliaLang/juliaup - Install VSCode as your programming environment: https://code.visualstudio.com/
- Install the Julia for VSCode extension: Open VSCode, go to Extensions, search for
Julia
and install.
These steps are simple, work for "any" operating system, and out of the box you get:
- A console for Julia which you can get by typing
Alt+J, Alt+O
in VSCode. - Using Julia in a scripting environment in VSCode. When working on a Julia script (
.jl
text file) you may evaluate any amount of code in the script interactively. E.g.,Ctrl+Enter
evaluates current line being edited. The Julia process that evaluates the script is the same as the one in the console you get in point 1. The Julia console and the text editor window are linked! - Jupyter notebooks, like the one you are reading now, which you can open from the command launch in VSCode (Ctrl+Shift+P) and then selecting "Jupyter: Import new notebook". Each Jupyter notebook launches a dedicated Julia process. Jupyter notebooks are not linked with the standard text editor and Julia console of VSCode!
Additional Julia packages that may be used during the workshop can be installed on the spot, but if you want to pre-compile everything then simply run
import Pkg
Pkg.add(["BenchmarkTools", "CairoMakie", "OrdinaryDiffEq", "DynamicalSystems", "DrWatson", "DataFrames"])
It is strongly encouraged to have an active mindset during this tutorial. Instead of only listening to my own boring voice, you should have a second Julia instance (e.g. REPL or a VSCode editor) and play around with the code and ideas I present. Ask questions during the tutorial, as there is a lot of time allocated for that!
Julia is a relatively new programming language, developed at MIT, with version 1.0 released in August 2018. Even though it is so recent, it has taken the scientific community by storm and many serious large scale projects have started using Julia.
The Julia documentation outlines the main facts and features of Julia.
I've put my thoughts on how to answer this question in Why Julia - a Manifesto.
Much of the material of this workshop is created by the author (George Datseris). However significant content comes from the following sources:
- The JuliaBox tutorials for the core language
- Exercises from exercism.io
- Chris Rackauckas' tutorials from http://ucidatascienceinitiative.github.io/IntroToJulia/
- Carsten Bauer's workshop https://github.com/crstnbr/JuliaWorkshop19
- Stefan Karpinski's JuliaCon talk, "The Unreasonable Effectiveness of Multiple Dispatch"
- Jonas Isensee's DrWatson talk at Julia users meetup (in UK, hosted by Invenia)
- https://github.com/mitmath/18330
- Kristoffer Carlsson and Fredrik Bagge Carlson's talk "Julia for AI and Data Science" https://www.youtube.com/watch?v=2MBD10lqWp8