lifecycles.algorithms.event_weights

event_weights(lc: LifeCycle, target: str, direction: str) dict

Compute the event weights of a target set in a lifecycle object.

Parameters:
  • lc – a LifeCycle object

  • target – the name of the target set

  • direction – the temporal direction in which the flow is to be analyzed

Returns:

a dictionary containing the event weights

Example:

>>> import lifecycles as lcs
>>> # ... create a lc object here ...
>>> weights = lcs.event_weights(lc, "1_0", "+")
>>> weights.keys()
dict_keys(['Death', 'Dispersion', 'Shrink', 'Reduction', 'Continue', 'Split', 'Ancestor', 'Disassemble'])