classix.aggregation.aggregate

classix.aggregation.aggregate(data, sorting='pca', tol=0.5)[source]

Aggregate the data

Parameters

datanumpy.ndarray

The input that is array-like of shape (n_samples,).

sortingstr

The sorting method for aggregation, default=’pca’, other options: ‘norm-mean’, ‘norm-orthant’.

tolfloat

The tolerance to control the aggregation. if the distance between the starting point of a group and another data point is less than or equal to the tolerance, the point is allocated to that group.

Returns

labels (list)

The group categories of the data after aggregation.

splist (list)

The list of the starting points.

nr_dist (int) :

The number of pairwise distance calculations.

ind (numpy.ndarray):

Array storing Sorting indices.

sort_vals (numpy.ndarray):

Sorting values.

data (numpy.ndarray):

Sorted data.