pypowsybl.network.Network.get_shunt_compensators#

Network.get_shunt_compensators(all_attributes=False, attributes=None, **kwargs)[source]#

Get a dataframe of shunt compensators.

Parameters:
  • all_attributes (bool) – flag for including all attributes in the dataframe, default is false

  • attributes (Optional[List[str]]) – attributes to include in the dataframe. The 2 parameters are mutually exclusive. If no parameter is specified, the dataframe will include the default attributes.

  • kwargs (Union[_SupportsArray[dtype[Any]], _NestedSequence[_SupportsArray[dtype[Any]]], bool, int, float, complex, str, bytes, _NestedSequence[Union[bool, int, float, complex, str, bytes]]]) – the data to be selected, as named arguments.

Returns:

A dataframe of shunt compensators.

Return type:

DataFrame

Notes

The resulting dataframe, depending on the parameters, will include the following columns:

  • model_type:

  • max_section_count: The maximum number of sections that may be switched on

  • section_count: The current number of section that may be switched on

  • p: the active flow on the shunt, NaN if no loadflow has been computed (in MW)

  • q: the reactive flow on the shunt, NaN if no loadflow has been computed (in MVAr)

  • i: the current in the shunt, NaN if no loadflow has been computed (in A)

  • voltage_level_id: at which substation the shunt is connected

  • bus_id: bus where this shunt is connected

  • bus_breaker_bus_id (optional): bus of the bus-breaker view where this shunt is connected

  • node (optional): node where this shunt is connected, in node-breaker voltage levels

  • connected: True if the shunt is connected to a bus

  • fictitious (optional): True if the shunt is part of the model and not of the actual network

This dataframe is indexed by the id of the shunt compensators

Examples

net = pp.network.create_ieee14()
net.get_shunt_compensators()

will output something like:

model_type

max_section_count

section_count

p

q

i

voltage_level_id

bus_id

connected

id

B9-SH

LINEAR

1

1

NaN

NaN

NaN

VL9

VL9_0

True

net = pp.network.create_ieee14()
net.get_shunt_compensators(all_attributes=True)

will output something like:

model_type

max_section_count

section_count

p

q

i

voltage_level_id

bus_id

connected

id

B9-SH

LINEAR

1

1

NaN

NaN

NaN

VL9

VL9_0

True

net = pp.network.create_ieee14()
net.get_shunt_compensators(attributes=['model_type','p','q','i','voltage_level_id','bus_id','connected'])

will output something like:

model_type

p

q

i

voltage_level_id

bus_id

connected

id

B9-SH

LINEAR

NaN

NaN

NaN

VL9

VL9_0

True