Grouped bar
using Deneb
data = (
category=collect("AAABBBCCC"),
group=collect("xyzxyzxyz"),
value=rand(9)
)
chart = Data(data) * Mark(:bar) * Encoding(
:category,
"value:q",
xOffset=:group,
color=:group,
)
The example above requires at least Vega v5.
Using the column encoding:
Data(data) * Mark(:bar, tooltip=true) * Encoding(
:group,
"value:q",
color=:group,
column=:category,
)
This page was generated using DemoCards.jl and Literate.jl.