DAG.existsArc
- DAG.existsArc(n1, n2)
Check if an arc exists between n1 and n2.
- Parameters:
n1 (
int) – the id of the tail noden2 (
int) – the id of the head node
- Returns:
True if the arc exists
- Return type:
bool
Example
import pyagrum as gum
dag = gum.fastDAG("A->B")
dag.existsArc(0, 1)
# True
dag.existsArc(1, 0)
# False
Class