Clusters class

This class describes a clustering.

Constructors

Clusters(List<List<double>> points, List<int> ignoredDims, List<int> clusters, List<List<double>> means)

Properties

clusterPoints List<List<List<double>>>
For each cluster, the list of points belonging to that cluster.
latefinal
clusters List<int>
For each point points[i], clusters[i] gives the index of the cluster that points[i] is a member of. The mean of the cluster is given by means[clusters[i]].
final
exactSilhouette double
Computes the average 'silhouette' over all points.
latefinal
hashCode int
The hash code for this object.
no setterinherited
ignoredDims List<int>
Dimensions of points that are ignored.
final
inertia double
Sum of squared distances of samples to their closest cluster center.
latefinal
k int
Convenience getter for the number of clusters.
no setter
means List<List<double>>
The means of the clusters.
final
points List<List<double>>
The list of all points in the clusters.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
silhouette double
Computes an approximation of the average 'silhouette' over all points.
latefinal

Methods

kNearestNeighbors(List<double> point, int k) int
Predict the cluster that point belongs to by way of a vote among its k nearest neighbors.
nearestMean(List<double> point) int
Returns the index of the mean that is closest to point.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited