NNSOM.utils.get_edge_widths

NNSOM.utils.get_edge_widths(indices, clust)[source]

Calculate edge line widths per cluster based on class membership fraction.

Width is proportional to the fraction of cluster members that belong to the given class, scaled to a maximum of 20.

Parameters:
  • indices (array-like of int) – Indices of data points belonging to the target class.

  • clust (list of array-like) – A list of cluster index arrays.

Returns:

lwidth – Line width for each cluster edge. None for empty clusters or clusters with no class members.

Return type:

np.ndarray, shape (numNeurons,)