API reference

andrey.metrics.orientation_scores#

andrey.metrics.orientation_scores(estimated, true)[source]#

Precision/recall/f1 of arrowhead (ARROW) marks – the orientation agreement.

For DAGs this is directed-edge F1 (one arrowhead per directed edge, a reversal is one false positive and one false negative); for PAGs it is arrowhead precision/recall.

Return type:

dict[str, float]

Examples

>>> orientation_scores([[0, 1], [0, 0]], [[0, 1], [0, 0]])["f1"]
1.0