Statistics#
Statistic functions which can be called within a pypsa.Network
via
n.statistics.func
. For example n.statistics.capex()
.
Statistic methods#
|
Calculate the capital expenditure of the network in given currency. |
|
Calculate the capital expenditure of already built components of the network in given currency. |
|
Calculate the capex of expanded capacities of the network components in currency. |
|
Calculate the optimal capacity of the network components in MW. |
|
Calculate the installed capacity of the network components in MW. |
|
Calculate the expanded capacity of the network components in MW. |
|
Calculate the operational expenditure in the network in given currency. |
|
Calculate the supply of components in the network. |
|
Calculate the withdrawal of components in the network. |
|
Calculate the transmission of branch components in the network. |
|
Calculate the energy balance of components in the network. |
|
Calculate the curtailment of components in the network in MWh. |
|
Calculate the capacity factor of components in the network. |
|
Calculate the revenue of components in the network in given currency. |
|
Calculate the market value of components in the network in given currency/MWh or currency/unit_{bus_carrier} where unit_{bus_carrier} is the unit of the bus carrier. |
Statistic groupers#
Groupers can be used via the groupby
argument in the statistic methods.
groupers = n.statistics.groupers
n.statistics.capex(groupby=groupers.carrier)
# or simply
n.statistics.capex(groupby='carrier')
All default groupers are defined in the pypsa.statistics.grouping.Groupers
class and currently included are, grouping by ..
Custom groupers can be registered on module level via
pypsa.statistics.groupers.add_grouper
.
The key will be used as identifier in the groupby
argument.
Groupers can also be used to create multiindexed groupers. For example, to group by bus and carrier:
groupers = n.statistics.groupers
n.statistics.capex(groupby=groupers['bus', 'carrier'])
# or simply
n.statistics.capex(groupby=['bus', 'carrier'])
|
Add a custom grouper to groupers on module level. |
List all available groupers which are avaliable on the module level. |
|
|
Grouper method to group by the carrier of the components. |
|
Grouper method to group by the carrier of the attached bus of a component. |
|
Grouper method to group by the name of components. |
|
Grouper method to group by the attached bus of the components. |
|
Grouper method to group by the country of the components corresponding bus. |
|
Grouper method to group by the unit of the components corresponding bus. |