lifecycles.LifeCycle.all_flows¶
- LifeCycle.all_flows(direction: str, min_branch_size: int = 1) dict¶
compute the flow of all groups w.r.t. a given temporal direction
- Parameters:
direction – the temporal direction in which the groups are to be analyzed
min_branch_size – the minimum size of a branch to be considered
- Returns:
a dictionary keyed by group name and valued by the flow of the group
- Example:
>>> lc = LifeCycle() >>> lc.add_partition([[1,2], [3,4,5]]) >>> lc.add_partition([[1,2,3], [4,5]]) >>> lc.all_flows("+") >>> # {'0_0': {'1_0': {1, 2}}, '0_1': {'1_0': {3}, '1_1': {4, 5}}}