Go to the documentation of this file. 1 #ifndef vtkKMeansDistanceFunctor_h
2 #define vtkKMeansDistanceFunctor_h
16 #include "vtkFiltersStatisticsModule.h"
111 #endif // vtkKMeansDistanceFunctor_h
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
A table, which contains similar-typed columns of data.
measure distance from k-means cluster centers
virtual vtkVariantArray * GetEmptyTuple(vtkIdType dimension)
Return an empty tuple.
vtkVariantArray * EmptyTuple
virtual int GetDataType()
Return the data type used to store cluster center coordinates.
abstract base class for most VTK objects
An array holding vtkVariants.
virtual vtkAbstractArray * CreateCoordinateArray()
Return a vtkAbstractArray capable of holding cluster center coordinates.
virtual void PackElements(vtkTable *curTable, void *vElements)
Pack the cluster center coordinates in vElements into columns of curTable.
~vtkKMeansDistanceFunctor() override
virtual void UnPackElements(vtkTable *curTable, vtkTable *newTable, void *vLocalElements, void *vGlobalElements, int np)
Unpack the cluster center coordinates in vElements into columns of curTable.
vtkKMeansDistanceFunctor()
a simple class to control print indentation
virtual void PairwiseUpdate(vtkTable *clusterCenters, vtkIdType row, vtkVariantArray *data, vtkIdType dataCardinality, vtkIdType totalCardinality)
This is called once per observation per run per iteration in order to assign the observation to its n...
Abstract superclass for all arrays.
virtual void PerturbElement(vtkTable *, vtkTable *, vtkIdType, vtkIdType, vtkIdType, double)
When a cluster center (1) has no observations that are closer to it than other cluster centers or (2)...
virtual void DeallocateElementArray(void *)
Free an array allocated with AllocateElementArray.
virtual void * AllocateElementArray(vtkIdType size)
Allocate an array large enough to hold size coordinates and return a void pointer to this array.
static vtkKMeansDistanceFunctor * New()
virtual void UnPackElements(vtkTable *curTable, void *vLocalElements, vtkIdType numRows, vtkIdType numCols)