pySimBlocks.project.plot_from_config¶
- pySimBlocks.project.plot_from_config.plot_from_config(logs: dict, plot_cfg: PlotConfig | None, show: bool = True, block: bool = True) None[source]¶
Plot logged simulation signals according to a
PlotConfig.Each signal component is plotted as a separate step curve. Labels follow the convention: scalar signals use
sig; column vector elements usesig[i]; matrix elements usesig[r,c].- Parameters:
logs – Dictionary of logged signals as returned by
run(). Must contain a'time'key.plot_cfg – Plot configuration. If None, the function returns immediately without producing any figures.
show – If True, call
plt.show()after creating all figures.block – Passed to
plt.show(); controls whether the call blocks.
- Raises:
KeyError – If any signal requested by
plot_cfgwas not logged, or if'time'is missing fromlogs.ValueError – If any logged signal is not a list of 2D arrays with a consistent shape.