Stacked Bar Chart

Stacked bar chart showing the composition of categories within each group.

Stacked Bar Chart


Graph

The chart shows how different groups are distributed across categories, with each bar representing a category and the stacked segments showing the contribution of each group.

Inputs

x
The data field for the x-axis representing categories or groups to be displayed as bars
y
The data field for the y-axis representing values to be aggregated and displayed as bar heights
color
The data field used to define different groups that will be stacked within each bar, creating distinct colored segments

Inputs Types

Input Types
x List, DataSeries, NDArray, DataRecords, DataFrame
y List, DataSeries, NDArray, DataRecords, DataFrame
color List, DataSeries, NDArray, DataRecords, DataFrame

You can check the list of supported types here: Available Type Hints.

Outputs

x
The processed x-axis data field used for chart categories
y
The processed y-axis data field used for chart values
color
The processed color grouping data field used for stacked segments

Outputs Types

Output Types
x List, DataSeries, NDArray, DataRecords, DataFrame
y List, DataSeries, NDArray, DataRecords, DataFrame
color List, DataSeries, NDArray, DataRecords, DataFrame

You can check the list of supported types here: Available Type Hints.

Options

The Stacked Bar Chart brick contains some changeable options:

'x' data field
Specifies the field name to use for the x-axis data mapping (default: "x")
'y' data field
Specifies the field name to use for the y-axis data mapping (default: "y")
Groups field
Specifies the field name to use for color grouping and stacking (default: "color")
'y' data aggregation
Defines how y-axis values should be aggregated, with options for "sum" or "count" (default: "count")

Brick Info

version v0.1.4
python 3.10, 3.11, 3.12, 3.13
requirements
    -