plot_cost_decomposition

Defined in fynance.plot

plot_cost_decomposition(cost_components, index=None, ax=None)[source]

Stack the cumulative cost components as a share of capital.

cost_components maps a component name (e.g. "transaction", "market_impact") to its per-step cost series; each is accumulated and stacked, so the panel reads as cumulative fees in % of capital broken down by source — the detail a single aggregate total_cost hides. Returns the matplotlib Axes.