comp.pat {lcd} | R Documentation |
Compares a (learned) chain graph pattern to the (supposed) true pattern. The two patterns should have the same vertex set in order for the function to return a meaningful result.
comp.pat(truepat, pat)
truepat |
the adjacency matrix of the true pattern. |
pat |
the adjacency matrix of the pattern to be compared with the true one. |
a.total |
total number of complex arrows on the true pattern. |
a.missing |
number of true complex arrows missing in the pattern to be compared. |
a.extra |
number of spurious complex arrows present in the pattern to be compared. |
shd |
structural Hamming distance from pat to truepat . |
Structural Hamming distance is defined as the total number of operations needed to convert one graph to the other. Each operation must be one of the following: (1) add or delete an undirected edge, or (2) add, remove or reverse an orientation of an edge.
Zongming Ma and Xiangrui Meng
Tsamardinos, I., Brown, L., and Aliferis, C. (2006). The max-min hill-climbing Bayesian network structure learning algorithm. Mach. Learn., 65(1):31-78.