graphclust.cluster.HybridMSTGG#
- class graphclust.cluster.HybridMSTGG(max_clusters=4, *, lambda_=2.0, depth=2, min_cluster_size=None, gath_geva=True, m=2.0, tol=0.0001, normalize=True)[source]#
Bases:
ClusterMixin,BaseEstimatorHybrid minimal spanning tree – Gath–Geva clustering (Vathy-Fogarassy, Feil and Abonyi 2005).
The data are scaled to the unit hypercube and their MST is built.
The cluster (subtree) with the largest hypervolume \(V_i=\sqrt{\det\mathbf{F}_i}\) is selected and split in two by
Zahn’s global criterion (edge longer than
lambda_times the mean edge of the subtree), elseZahn’s local criterion (edge longer than
lambda_times the mean of the edges withindepthsteps), elsethe hypervolume criterion: the edge whose removal minimizes the total fuzzy hypervolume \(\mathrm{FHV}=\sum_i V_i\) of the partition.
The volume criterion cuts chains and bends that no length criterion detects. Cuts that would leave fewer than
min_cluster_sizesamples on either side are not considered.Step 2 is repeated until
max_clustersclusters exist.With
gath_geva=Truethe crisp partition initializesgraphclust.fuzzy.GathGeva, which returns memberships, centers and covariance matrices (a mixture of Gaussians).
- Attributes:
- tree_labels_
crisplabelsaftertheMSTcutting - labels_
finallabels(Gath–Gevaargmaxifused) - membership_, cluster_centers_, covariances_
fromGath–Geva - split_history_
listofdicts(cluster,edge,criterion,volumes)
- tree_labels_