import polars as pl
from reactable import Reactable, Column, ColGroup, embed_css
from reactable.data import penguins
= penguins.to_polars()
pl_penguins
embed_css()
Column headers
You can create column groups by passing a list of ColGroup()
definitions to column_groups=
:
Reactable(5, ["species", "island", "bill_length_mm", "bill_depth_mm"]],
pl_penguins[:=[
columnsid="bill_length_mm", name="Length (mm)"),
Column(id="bill_depth_mm", name="Depth (mm)"),
Column(id="species", name="Species"),
Column(id="island", name="Island"),
Column(
],=[
column_groups="Bill", columns=["bill_length_mm", "bill_depth_mm"]),
ColGroup(name
], )