ragraph.analysis.comparison._sigma
#
Sigma analysis module.
Module Contents#
Classes#
Basic class to perform a sigma analysis on |
- class ragraph.analysis.comparison._sigma.SigmaAnalysis(graphs: List[ragraph.graph.Graph], mode: str = 'fraction')#
Basic class to perform a sigma analysis on
ragraph.graph.Graph
objects.- Parameters:
graphs – List of graphs to compare. mode: One of “absolute” or “fraction”.
mode – Determines whether edge label overlap should be calculated as an absolute count over all edges between certain nodes or whether a fraction (percentage of label occurrence) is calculated as edge weights. Defaults to fraction.
Note
Graphs are compared on leaf node level. The resulting sigma or overlap is currently only calculated in terms of overlapping edge labels.
Note
Apart of label occurence, the overall edge occurence is also added as an Edge weight, named “_occurence”. (The underscore prefix is added so it doesn’t collide with regular label names)
- property graphs: List[ragraph.graph.Graph]#
List of graphs to be compared.
- property mode: str#
Edge weight mode.
- property nodes: List[ragraph.node.Node]#
List of leaf nodes within the graph.
- property node_dict: Dict[str, ragraph.node.Node]#
Dictionary of node name to node.
- property edges: List[ragraph.edge.Edge]#
- property edge_dict: Dict[Tuple[str, str], List[ragraph.edge.Edge]]#
Dictionary of source and target names to list of edges.
- _reset_lazy_props()#
Reset all lazy properties.
- _get_edge_weights(edges: List[ragraph.edge.Edge]) Dict[str, Union[int, float]] #
Compute weights for edge in Sigma DSM from the provided list of edges.