get_statistics

get_statistics(graph, axis=None, norm_graph=None)[source]

Extract summary statistics from each feature array in the graph’s hyper-edge sets.

For every feature of every hyper-edge in graph, computes:
  • Root Mean Squared Error (RMSE)

  • Mean Absolute Error (MAE)

  • First and second moments (mean, standard deviation)

  • Range and quantiles (min, 10th, 25th, 50th, 75th, 90th, max)

If norm_graph is provided, then it also returns normalized metrics:
  • Normalized RMSE (nrmse)

  • Normalized MAE (nmae)

Parameters:
  • graph (Graph) – Graph object containing hyper-edge sets with feature dictionaries.

  • axis (int | None) – Axis along which to compute statistics. If None, statistics are computed over the flattened array.

  • norm_graph (Graph | None) – Optional Graph whose features serve as normalization reference.

Returns:

A dictionary mapping keys of the form "{hyper_edge_set_name}/{feature_name}/{stat}" to their computed values. Values are floats or numpy arrays depending on axis.

Return type:

dict