GClasses
|
This is a base class for clustering algorithms that operate on sparse matrices. More...
#include <GCluster.h>
Public Member Functions | |
GSparseClusterer (size_t clusterCount) | |
virtual | ~GSparseClusterer () |
size_t | clusterCount () |
Return the number of clusters. | |
virtual void | cluster (GSparseMatrix *pData)=0 |
Perform clustering. | |
virtual size_t | whichCluster (size_t nVector)=0 |
Report which cluster the specified row is a member of. | |
void | setMetric (GSparseSimilarity *pMetric, bool own) |
If own is true, then this takes ownership of pMetric. | |
Protected Attributes | |
size_t | m_clusterCount |
GSparseSimilarity * | m_pMetric |
bool | m_ownMetric |
This is a base class for clustering algorithms that operate on sparse matrices.
GClasses::GSparseClusterer::GSparseClusterer | ( | size_t | clusterCount | ) |
virtual GClasses::GSparseClusterer::~GSparseClusterer | ( | ) | [virtual] |
virtual void GClasses::GSparseClusterer::cluster | ( | GSparseMatrix * | pData | ) | [pure virtual] |
Perform clustering.
Implemented in GClasses::GKMedoidsSparse, and GClasses::GKMeansSparse.
size_t GClasses::GSparseClusterer::clusterCount | ( | ) | [inline] |
Return the number of clusters.
void GClasses::GSparseClusterer::setMetric | ( | GSparseSimilarity * | pMetric, |
bool | own | ||
) |
If own is true, then this takes ownership of pMetric.
virtual size_t GClasses::GSparseClusterer::whichCluster | ( | size_t | nVector | ) | [pure virtual] |
Report which cluster the specified row is a member of.
Implemented in GClasses::GKMedoidsSparse, and GClasses::GKMeansSparse.
size_t GClasses::GSparseClusterer::m_clusterCount [protected] |
bool GClasses::GSparseClusterer::m_ownMetric [protected] |
GSparseSimilarity* GClasses::GSparseClusterer::m_pMetric [protected] |