Metrics#

Metrics for evaluating learned structures, implied independencies, and fitted models.

Supervised Metrics#

SHD()

Computes the Structural Hamming Distance between true_causal_graph and est_causal_graph.

AdjacencyConfusionMatrix([metrics])

Computes confusion matrix based metrics for comparing causal graph skeletons.

OrientationConfusionMatrix([metrics])

Computes confusion matrix based metrics for comparing edge orientations in DAGs.

Unsupervised Metrics#

CorrelationScore([ci_test, score, ...])

Score to compute how well the model structure represents the correlations in the data.

ImpliedCIs([ci_test, show_progress])

Tests the implied Conditional Independences (CI) of the DAG in the given data.

FisherC([ci_test, compute_rmsea, show_progress])

Returns a p-value for testing whether the given data is faithful to the model structure's constraints.

StructureScore([scoring_method])

Uses the standard model scoring methods to give a score for each structure.

Utilities#

get_metrics(**kwargs)

Get metric classes matching the given tag filters.