compareDag function

Compare two DAGs or EGs