connected_components_generator(graph: networkx.classes.graph.Graph) → Generator[networkx.classes.graph.Graph, None, None]¶
Returns a Generator that will provide each component as a networkx.Graph copy
Parameters: graph (networkx.Graph) – The networkx graph object to create a connected component generator from Returns: A Generator that returns a copy of the subgraph corresponding to a connected component of graph Return type: Generator[networkx.Graph]
largest_connected_component(graph: networkx.classes.graph.Graph, weakly: bool = True) → networkx.classes.graph.Graph¶
Returns the largest connected component of the graph.
A copy of the largest connected component as an nx.Graph object
number_connected_components(graph: networkx.classes.graph.Graph) → int¶
Returns the number of connected components in the Graph.
This function calls the appropriate newtorkx connected components function depending on whether it is Undirected or Directed.
Parameters: graph (networkx.Graph) – The networkx graph object to determine the number of connected components for Returns: number of connected components (and in the case of a directed graph, strongly connected) Return type: int
A PartitionedGraph combines a networkx graph object with a global community partitioning for that graph.
Alias for field number 1
Alias for field number 0
self_loop_augmentation(graph: networkx.classes.graph.Graph, weight_column: str = 'weight') → networkx.classes.graph.Graph¶
Generates a self loop for each vertex in the graph with a generated weight for each vertex that is the ratio between its degree in the graph and the total number of other vertices in the graph, excluding the original self loop.
This should be used prior to Spectral Embedding techniques to ensure that there is a reasonable value for each vertex as it will appear in an adjacency matrix.
Modifies the provided graph in place as well as returning it.
The networkx Graph object that was modified in place.
- topologic.embedding package
- topologic.embedding.clustering package
- topologic.embedding.distance package
- topologic.embedding.metric package
- topologic.io package
- topologic.partition package
- topologic.projection package
- topologic.similarity package
- topologic.statistics package