graphclust.datasets#

Benchmark data for graph-based clustering and visualization.

Synthetic generators (all return X, y and take random_state):

load_boxlinecircle() returns the original 7100-point data set of the authors (shipped with the package). Real data sets come from scikit-learn: load_iris(), load_wine(), load_breast_cancer(), load_digits().

Synthetic generators and bundled example data.

Functions#

load_boxlinecircle()

The original 'boxlinecircle' data of Vathy-Fogarassy and Abonyi (7100 x 3; no labels).

load_breast_cancer()

Wisconsin diagnostic breast cancer data (569 x 30, 2 classes) as shipped with scikit-learn.

load_digits()

Handwritten digits (1797 x 64, 10 classes), a stand-in for the Semeion digits of the book.

load_iris()

Iris flowers (150 x 4, 3 classes).

load_wine()

Wine recognition data (178 x 13, 3 cultivars).

make_boxlinecircle([n_box, n_line, ...])

A noisy cube, a bent line and a circle in 3-D (shapes of dimension 3, 1 and 1).

make_chainlink([random_state, normalize])

ChainLink data: 75 points in 2-D -- three compact clusters, two of which are joined by a chain of points.

make_curves([random_state, normalize])

Curves data: 267 points in 2-D forming four curved clusters of different size that nearly touch.

make_s_curve([n_samples, noise, random_state])

S-curve manifold (scikit-learn generator); y is the position along the curve.

make_swiss_roll([n_samples, noise, random_state])

Swiss roll manifold (scikit-learn generator); y is the position along the roll.

make_variety([random_state, normalize])

Variety data: 100 points in 2-D, clusters of 22 (dense, round), 26 (elongated) and 51 (sparse) points and one outlier.

minmax_scale(X)

Scale every feature to [0, 1] (constant features become 0).