Check Markov equivalence of two DAGs | R Documentation |
Check Markov equivalence of two DAGs.
equivdags(g1, g2)
g1 |
The matrix of a DAG or a partially directed graph as produced from |
g2 |
The matrix of a DAG or a partially directed graph as produced from |
Two DAGs are Markov equivalent if a) they have the same adjancencies (regardlsee of the mark, arrowhead, tail or nothing) and b) they have the same unshielded colliders.
A list including:
apofasi |
A boolean variable, TRUE of FALSE. |
mes |
A message specyfying the result, the dimensions of the adjacency matrices do not match for example, or the number of adjancencies is not the same, they do not share the same unshilded colliders, or they are Markov equivalent. |
Michail Tsagris
R implementation and documentation: Giorgos Athineou <athineou@csd.uoc.gr> and Michail Tsagris mtsagris@uoc.gr
Tsamardinos, Brown and Aliferis (2006). The max-min hill-climbing Bayesian network structure learning algorithm. Machine learning, 65(1), 31-78.
pc.or, mmhc.skel, pc.con
y <- rdag(1000, 10, 0.3) tru <- y$G x <- y$x mod <- pc.con(x) eg <- dag2eg(y$G) ## make it essential graph first est <- pc.or(mod)$G equivdags(est, tru)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.