fuzzyclust.extensions#

Robust and shape-oriented variants of fuzzy c-means.

FCM assumes compact, roughly spherical clusters of similar size and is pulled away by outliers. The estimators of this sub-package relax one of these assumptions at a time:

PCM, PFCM, noise clustering, kernel FCM, fuzzy c-varieties and c-shells.

Classes#

PCM([n_clusters, m, eta, eta_scale, tol, ...])

Possibilistic c-means clustering (Krishnapuram and Keller).

PFCM([n_clusters, m, eta, a, b, gamma, ...])

Possibilistic fuzzy c-means clustering (Pal, Pal, Keller and Bezdek).

NoiseClustering([n_clusters, m, delta, ...])

Noise clustering: fuzzy c-means with a virtual noise cluster (Davé).

KernelFCM([n_clusters, m, kernel, gamma, ...])

Kernel fuzzy c-means: FCM in the feature space of a Mercer kernel.

FuzzyCVarieties([n_clusters, m, n_dims, ...])

Fuzzy c-varieties (FCV) clustering: linear-variety prototypes (Bezdek et al.).

FuzzyCShells([n_clusters, m, algorithm, ...])

Fuzzy c-(spherical) shells: circles / hyperspheres as prototypes.

VolumePrototypeFCM([n_clusters, m, norm, ...])

Fuzzy c-means with volume prototypes and optional adaptive cluster merging (Kaymak & Setnes, 2002).

SCAD([n_clusters, m, variant, q, delta, ...])

Simultaneous clustering and attribute discrimination (Frigui & Nasraoui, 2004).

FeatureWeightedFCM([n_clusters, m, t, tol, ...])

Fuzzy c-means with global attribute weights (after Huang et al., 2005).

Functions#

rbf_kernel(X, Y, gamma)

Gaussian (RBF) kernel matrix \(K_{kl}=\exp(-\gamma\|\mathbf{x}_k-\mathbf{y}_l\|^2)\).

plot_shells(X, model[, ax, labels])

Scatter the data and draw the fitted circles of a FuzzyCShells model.

plot_varieties(X, model[, ax, labels, length])

Scatter the data and draw the fitted lines of a FuzzyCVarieties model (n_dims=1).

plot_typicality(X, T[, ax, cmap, s, label])

Scatter plot colored by the maximal typicality \(\max_i t_{ik}\) of every sample.

make_circles([centers, radii, ...])

Intersecting circles (shell clusters) with optional arcs and outliers.

make_close_blobs([sizes, spreads, distance, ...])

Two Gaussian clusters of different size and density close to each other.

make_crossing_lines([n_lines, ...])

Line segments that cross at a common point.

make_collinear_segments([...])

Two collinear segments separated by a gap, optionally with a third, oblique segment.

Constants#

KERNELS

Built-in immutable sequence.