Note

Deprecated wrapper. Prefer mario.Database.plot(...) for new code.

Database.plot_matrix(
matrix,
x,
color,
y='Value',
item='Sector',
facet_row=None,
facet_col=None,
animation_frame='Scenario',
base_scenario=None,
path=None,
mode='stack',
layout=None,
auto_open=True,
shared_yaxes='all',
shared_xaxes=True,
**filters,
)#

Deprecated wrapper around plot() for matrix bar plots.

Parameters:
  • matrix – Matrix or block name to visualize.

  • x – Column used on the x axis in the generated long-form plot.

  • color – Column used to color bars.

  • y – Column used on the y axis. The default is "Value".

  • item – Item dimension used to interpret the matrix for plotting. For SUT tables this controls whether the commodity or activity side is shown.

  • facet_row – Optional columns used to facet the plot.

  • facet_col – Optional columns used to facet the plot.

  • animation_frame – Column used to animate the plot, typically "Scenario".

  • base_scenario – Optional reference scenario used to plot differences.

  • path – Output HTML path. When omitted, MARIO writes to the default plots directory.

  • mode – Plotly bar mode, such as "stack" or "group".

  • layout – Optional layout dictionary overriding the default plot layout.

  • auto_open – When True, open the generated HTML plot automatically.

  • shared_yaxes – Axis-sharing options forwarded to the plotting backend.

  • shared_xaxes – Axis-sharing options forwarded to the plotting backend.

  • **filters – Named plot filters such as filter_region_from or filter_satellite_account.

Returns:

The plot is written to disk.

Return type:

None