7 Data Visualization with AlgebraOfGraphics.jl

AlgebraOfGraphics.jl is a higher-level plotting package that uses Makie.jl under the hood. It is geared towards data visualization workflows with support for DataFrames. AlgebraOfGraphics.jl abstracts away some common patterns in data visualization using an interface similar to R’s ggplot2 package.

AlgebraOfGraphics.jl follows a layered approach to construct visualizations in a structured manner. There are four main types of layers:

NOTE: AlgebraOfGraphics.jl has some guiding principles described in their philosophy section.

AlgebraOfGraphics.jl allows you to construct all of these types of layers with functions that return a Layer object, in which all of the information necessary will be encoded. You can then perform two operations on layers:

Finally, as the name suggests, AlgebraOfGraphics.jl is an algebra for Layer objects. And, as such, it defines two algebraic properties. Let a, b and c be Layer objects, then the following two properties hold:

To get started with AlgebraOfGraphics.jl, you’ll need to load it along with a desired Makie.jl backend (Chapter 6):

using AlgebraOfGraphics
using CairoMakie

Support this project
CC BY-NC-SA 4.0 Jose Storopoli, Rik Huijzer, Lazaro Alonso