network_topology#
- class braintools.visualize.network_topology(adjacency, positions=None, node_colors=None, edge_colors=None, node_sizes=None, edge_widths=None, ax=None, figsize=(10, 10), layout='spring', title=None, **kwargs)#
Visualize network topology from adjacency matrix.
- Parameters:
adjacency (
ndarray) – Adjacency matrix of the network.positions (
ndarray|None) – Node positions (N, 2). If None, uses layout algorithm.node_colors (
ndarray|None) – Colors for nodes.edge_colors (
ndarray|None) – Colors for edges.node_sizes (
ndarray|None) – Sizes for nodes.edge_widths (
ndarray|None) – Widths for edges.ax (
Axes|None) – Axes to plot on.figsize (
Tuple[float,float]) – Figure size if creating new figure.layout (
str) – Layout algorithm: ‘spring’, ‘circular’, ‘random’.**kwargs – Additional arguments passed to scatter (for nodes).
- Returns:
ax – The axes object containing the plot.
- Return type:
Axes