9.12. Vulnerability Functions
- plotter.plot_vulnerability_function(intensities, loss, cov, imt_label, loss_label, title=None, pFlag=True, export_path=None)[source]
Generate a vulnerability analysis plot featuring Beta distributions and a mean loss curve.
This method visualizes the uncertainty in loss ratios across different seismic intensities. It simulates Beta distributions based on mean loss and CoV, rendering them as truncated violin plots (strictly bounded 0-1) to represent the physical limits of structural damage.
The figure uses
self.figsizewithconstrained_layoutand is saved withoutbbox_inches='tight'so that every output image has identical, deterministic pixel dimensions.- Parameters:
intensities (list of float) – Intensity Measure (IM) levels (e.g., PGA, Sa) analyzed.
loss (list of float) – Mean loss ratios (0.0 to 1.0) corresponding to each intensity.
cov (list of float) – Coefficient of Variation for loss at each intensity.
imt_label (str) – Label for the X-axis (e.g., ‘PGA [g]’).
loss_label (str) – Label for the primary Y-axis loss curve (e.g., ‘Mean Damage Ratio’).
title (str, optional) – Custom plot title.
pFlag (bool, optional, default=True) – If True, the plot is processed (saved/shown).
export_path (str, optional) – Full path including filename to save the plot. Creates directories if missing.
- Return type:
None