pypsa.statistics.StatisticsAccessor.energy_balance

pypsa.statistics.StatisticsAccessor.energy_balance#

StatisticsAccessor.energy_balance(comps=None, aggregate_time='sum', aggregate_groups='sum', groupby=<function get_carrier_and_bus_carrier>, at_port=True, bus_carrier=None, nice_names=None, kind=None)#

Calculate the energy balance of components in the network. Positive values represent a supply and negative a withdrawal. Units depend on the regarded bus carrier.

For information on the list of arguments, see the docs in Network.statistics or pypsa.statistics.StatisticsAccessor.

Additional parameter#

aggregate_bus: bool, optional

Whether to obtain the nodal or carrier-wise energy balance. Default is True, corresponding to the carrier-wise balance.

aggregate_timestr, bool, optional

Type of aggregation when aggregating time series. Note that for {‘mean’, ‘sum’} the time series are aggregated to MWh using snapshot weightings. With False the time series is given in MW. Defaults to ‘sum’.