graphical_models.classes.dags.dag.DAG.optimal_fully_orienting_single_node_interventions

DAG.optimal_fully_orienting_single_node_interventions(cpdag=None, new=False, verbose=False) Set[Hashable][source]

Find the smallest set of interventions which fully orients the CPDAG into this DAG.

Parameters
  • cpdag – the starting CPDAG containing known orientations. If None, compute and use the observational essential graph.

  • new – TODO: remove after checking that directed clique tree method works.

  • verbose – TODO: describe.

Returns

A minimum-size set of interventions which fully orients the DAG.

Return type

interventions

Examples

>>> from graphical_models import DAG
>>> import itertools as itr
>>> d = DAG(arcs=set(itr.combinations(range(5), 2)))
>>> ivs = d.optimal_fully_orienting_single_node_interventions()
>>> ivs
{1, 3}