mcs_order#
- causalbase.graph.mcs_order(adj)[source]#
Compute a maximum cardinality search (MCS) ordering.
Repeatedly picks the unnumbered node adjacent to the most numbered ones, breaking ties by lowest index.
- Parameters:
- adjnp.ndarray
Symmetric boolean adjacency matrix of an undirected graph.
- Returns:
- list[int]
A permutation of
range(adj.shape[0]): the MCS visitation order.