hist
using CairoMakie, Distributions, Random
Random.seed!(124)
cmap = resample_cmap(:linear_wcmr_100_45_c42_n256, 256;
alpha = rand(256))
fig = Figure(resolution = (600,400))
ax = Axis(fig[1,1]; )
hist!(rand(Normal(2.6,0.4), 1000), normalization = :pdf, offset = -1,
color = :values, colormap = :plasma, direction = :x, fillto = -0.5)
hist!(rand(Normal(2.6,0.4), 1000), normalization = :pdf, offset = 1,
color = :grey10, direction = :x, scale_to = -0.5)
hist!(rand(Normal(0.2,0.2), 1000), normalization = :pdf, offset = 4,
strokewidth = 1, color = :transparent, strokecolor = :black,
direction = :y, scale_to = -1)
hist!(rand(Normal(0.2,0.2), 1000), normalization = :pdf, color = :values,
colormap = cmap, strokewidth = 1, strokecolor = :black,
bar_labels = :values, label_color = :black, label_size = 12,
label_formatter=x-> round(x, digits=1))
hidedecorations!(ax; grid = false)
fig
Warning
This example was autogenerated using:
using Pkg
Pkg.status(["CairoMakie", "Distributions"])
Status `~/work/BeautifulMakie/BeautifulMakie/docs/Project.toml`
[13f3f980] CairoMakie v0.10.6
[31c24e10] Distributions v0.25.96
This page was generated using Literate.jl.