temporalmapper.plotting.time_semantic_plot
- temporalmapper.plotting.time_semantic_plot(mapper, semantic_axis, ax=None, vertices=None, cluster_labels={}, cluster_label_kwargs={}, edge_labels=None, bundle=False, layout='barycenter', layout_kwargs={}, edge_scaling=1, node_scaling=1, node_size_bounds: tuple[float] = (5, 25), edge_weight_bounds: tuple[float] = (5, 25), node_size_scale='linear', node_kwargs={}, edge_kwargs={})
Create a time-semantic plot of the mapper graph.
- mapper: temporal_mapper.TemporalMapper
The temporal mapper object to plot.
- semantic_axis: ndarray
Array of shape
(n_samples,)with the 1D semantic data to use in the plot.- ax: matplotlib.axes (optional, default=None)
Matplotlib axis to draw on
- vertices: list (optional, default=None)
List of nodes in mapper.graph to include in the plot.
- cluster_labels: dict (optional, default={})
Dictionary of labels with cluster_labels[node] a string to label vertex node.
- cluster_label_kwargs: dict (optional, default={})
Keyword arguments for matplotlib.axis.text used when plotting cluster labels.
- edge_labels: dict (optional, default=None)
Dictionary of labels with edge_labels[e] a string to label edge e.
- bundle: bool (optional, default=False)
If true, uses the edge-bundling algorithm from datashader to plot edges.
- layout: string (optional, default=’barycenter’)
Optimization method used to reduce edge-crossings: one of None, “none”, “force-directed” or “barycenter”
- edge_scaling: float (optional, default = 1)
Scales the thickness of edges, larger is thicker.
- node_scaling: float (optional, default = 10)
Scales the size of vertices
- node_size_scale: string (optional, default=’linear’)
Specifies linear, sigmoid or logarithmic scaling for node sizes
- bundle: bool (optional, default=False)
If true, bundle the edges of the graph using datashader’s hammer_bundle function.
- node_kwargs: dict (optional, default={})
Keyword arguments passed to networkx.draw_networkx_nodes()
- edge_kwargs: dict (optional, default={})
Keyword arguments passed to networkx.draw_networkx_edges()
- matplotlib.axes.Axes
The Axes object containing the temporal plot.