cluster¶
Import in python using from mcot.core._scripts.parcel.cluster import cluster
-
mcot.core._scripts.parcel.cluster.cluster(similarity, method='spectral', n_clusters=10, **kwargs)[source]¶ Cluster based on a similarity graph
Parameters: - similarity – (N, N) sparse similarity matrix
- method – clustering method (‘spectral’, ‘affinity’, or ‘DBSCAN’)
- n_clusters – number of clusters
Returns: (N, ) integer array of labels