StructuralMetrics.tp_skeleton

StructuralMetrics.tp_skeleton()

Number of true positives at the skeleton level (undirected edges correctly predicted, ignoring orientation).

Returns:

True-positive count for the skeleton.

Return type:

float

Example

import pyagrum as gum

ref = gum.fastDAG("A->B->C;A->D")
test = gum.fastDAG("A->B;C->B;A->D")  # B->C is reversed
sm = gum.StructuralMetrics()
sm.compare(ref, test)
sm.tp()
# 2.0
sm.tp_skeleton()  # orientations are ignored
# 3.0

Class

StructuralMetrics