mario.Database.shock_calc#
- Database.shock_calc(io, z=False, u=False, s=False, e=False, ea=False, ec=False, v=False, va=False, vc=False, Y=False, Ya=False, Yc=False, clusters=None, notes=[], scenario=None, force_rewrite=False, **legacy_clusters)#
Apply shocks to coefficients or demand and store the result as a scenario.
- Parameters:
io – Shock definition source understood by the shock readers, typically an Excel workbook path.
z – Select which shock blocks should be read and applied from
io. For SUT databases, MARIO first looks for split-native worksheets:u/sforz,va/vcforv,ea/ecforeandYa/YcforY. When they are not present it falls back to the legacy unified worksheetsz,v,eandY.e – Select which shock blocks should be read and applied from
io. For SUT databases, MARIO first looks for split-native worksheets:u/sforz,va/vcforv,ea/ecforeandYa/YcforY. When they are not present it falls back to the legacy unified worksheetsz,v,eandY.v – Select which shock blocks should be read and applied from
io. For SUT databases, MARIO first looks for split-native worksheets:u/sforz,va/vcforv,ea/ecforeandYa/YcforY. When they are not present it falls back to the legacy unified worksheetsz,v,eandY.Y – Select which shock blocks should be read and applied from
io. For SUT databases, MARIO first looks for split-native worksheets:u/sforz,va/vcforv,ea/ecforeandYa/YcforY. When they are not present it falls back to the legacy unified worksheetsz,v,eandY.u – Optional aliases for the split SUT shock sheets. These are promoted to the corresponding legacy selectors
z,v,eandYso calls such asshock_calc(..., s=True)orshock_calc(..., Yc=True)work directly.s – Optional aliases for the split SUT shock sheets. These are promoted to the corresponding legacy selectors
z,v,eandYso calls such asshock_calc(..., s=True)orshock_calc(..., Yc=True)work directly.va – Optional aliases for the split SUT shock sheets. These are promoted to the corresponding legacy selectors
z,v,eandYso calls such asshock_calc(..., s=True)orshock_calc(..., Yc=True)work directly.vc – Optional aliases for the split SUT shock sheets. These are promoted to the corresponding legacy selectors
z,v,eandYso calls such asshock_calc(..., s=True)orshock_calc(..., Yc=True)work directly.ea – Optional aliases for the split SUT shock sheets. These are promoted to the corresponding legacy selectors
z,v,eandYso calls such asshock_calc(..., s=True)orshock_calc(..., Yc=True)work directly.ec – Optional aliases for the split SUT shock sheets. These are promoted to the corresponding legacy selectors
z,v,eandYso calls such asshock_calc(..., s=True)orshock_calc(..., Yc=True)work directly.Ya – Optional aliases for the split SUT shock sheets. These are promoted to the corresponding legacy selectors
z,v,eandYso calls such asshock_calc(..., s=True)orshock_calc(..., Yc=True)work directly.Yc – Optional aliases for the split SUT shock sheets. These are promoted to the corresponding legacy selectors
z,v,eandYso calls such asshock_calc(..., s=True)orshock_calc(..., Yc=True)work directly.clusters – Preferred cluster payload. When omitted, MARIO uses clusters already stored on the database, optionally merged with any legacy keyword clusters.
notes – Optional metadata notes attached to the created scenario.
scenario – Name of the output scenario. When omitted, MARIO creates
shock <n>automatically.force_rewrite – When
True, allow overwriting an existing non-baseline scenario.**legacy_clusters – Backward-compatible cluster mappings passed as keyword arguments.
- Returns:
The shocked scenario is materialized on the current database.
- Return type:
None