plot_stacked_bar
Create stacked bar charts to show how a categorical variable breaks down within another. Display raw counts or normalized percentages for clearer part-to-whole comparisons.
Instructions
Stacked bar chart showing composition of one categorical within another. normalize=True shows percentages (100% stacked), False shows raw counts. Example: plot_stacked_bar(column="ProductCode", by="CargoType", normalize=True)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| by | Yes | ||
| top_n | No | ||
| column | Yes | ||
| df_name | No | ||
| normalize | No | ||
| save_path | No |