RFFMakie.jl

Resources for the Future theme for the Makie.jl plotting package
Author e4st-dev
Popularity
3 Stars
Updated Last
9 Months Ago
Started In
August 2022

RFFMakie.jl

GitHub contributors GitHub last commit License: GPL v3 CI Code Coverage

Theming and color guidance for Resources for the Future comes from here. This package exports theme_rff to be used with Makie using the set_theme! function.

Installation

using Pkg
Pkg.add("RFFMakie")

Usage

RFFMakie is a very simple package that re-exports Makie and CairoMakie (its publication quality backend). RFFMakie defines colors and gives a theme called theme_rff. To learn how to use Makie.jl, see the extensive Makie documentation.

Example Plot

using RFFMakie
# fig = example_plot()

set_theme!(theme_rff())
fig = Figure()
ax = fig[1,1] = Axis(f, title="My Title")
lines!(ax, 1:50, cumsum(randn(50)), label="My thing 1")
lines!(ax, 1:50, cumsum(randn(50)), label="My thing 2")
lines!(ax, 1:50, cumsum(randn(50)), label="My thing 3")
lines!(ax, 1:50, cumsum(randn(50)), label="My thing 4")
scatter!(ax, 1:5:50, zeros(length(1:5:50)), label="My other 1")
scatter!(ax, 1:5:50, 3*ones(length(1:5:50)), label="My other 2")
fig[1,2] = Legend(f, ax, "Legend")
save("example.svg", fig) # or .png or .pdf

example_plot

RFF Colors

rff_colors() # Returns a vector of all the themed colors
rff_colors(1) # Returns single color
rff_colors.([1,2,3,4]) # Returns a vector of each of those colors

example_colors

Used By Packages

No packages found.