kmeans
k-means clustering in C++
Loading...
Searching...
No Matches
kmeans::Results< Index_, Cluster_, Float_ > Struct Template Reference

Results of the k-means clustering. More...

#include <kmeans.hpp>

Public Attributes

std::vector< Cluster_ > clusters
 
std::vector< Float_ > centers
 
Details< Index_ > details
 

Detailed Description

template<typename Index_, typename Cluster_, typename Float_>
struct kmeans::Results< Index_, Cluster_, Float_ >

Results of the k-means clustering.

Member Data Documentation

◆ centers

template<typename Index_ , typename Cluster_ , typename Float_ >
std::vector<Float_> kmeans::Results< Index_, Cluster_, Float_ >::centers

An array of length equal to the product of the number of dimensions and clusters. This contains a column-major matrix where each row corresponds to a dimension and each column corresponds to a cluster. Each column contains the centroid coordinates for the associated cluster.

◆ clusters

template<typename Index_ , typename Cluster_ , typename Float_ >
std::vector<Cluster_> kmeans::Results< Index_, Cluster_, Float_ >::clusters

An array of length equal to the number of observations, containing the 0-indexed cluster assignment for each observation. Each entry is less than the number of clusters.

◆ details

template<typename Index_ , typename Cluster_ , typename Float_ >
Details<Index_> kmeans::Results< Index_, Cluster_, Float_ >::details

Further details from running the chosen k-means algorithm.


The documentation for this struct was generated from the following file: