
public class ProjectedCentroid extends Centroid
DatabaseUtil for
 easier to use APIs.NumberVector.Factory<V extends NumberVector<? extends N>,N extends Number>| Modifier and Type | Field and Description | 
|---|---|
private BitSet | 
dims
The selected dimensions. 
 | 
elements, ERR_MATRIX_INNERDIM, ERR_VEC_DIMENSIONS| Constructor and Description | 
|---|
ProjectedCentroid(BitSet dims,
                 int dim)
Constructor for updating use. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
static ProjectedCentroid | 
make(BitSet dims,
    Relation<? extends NumberVector<?>> relation)
Static Constructor from a relation. 
 | 
static ProjectedCentroid | 
make(BitSet dims,
    Relation<? extends NumberVector<?>> relation,
    DBIDs ids)
Static Constructor from a relation. 
 | 
void | 
put(double[] val)
Add a single value with weight 1.0. 
 | 
void | 
put(double[] val,
   double weight)
Add data with a given weight. 
 | 
void | 
put(NumberVector<?> val)
Add a single value with weight 1.0. 
 | 
void | 
put(NumberVector<?> val,
   double weight)
Add data with a given weight. 
 | 
make, make, make, put, put, toVectorbyteValue, clone, copy, cross3D, doubleValue, equals, euclideanLength, floatValue, get, getArrayCopy, getArrayRef, getColumnVector, getDimensionality, getMax, getMin, getValue, hashCode, intValue, longValue, minus, minusEquals, minusEquals, minusTimes, minusTimesEquals, normalize, plus, plusEquals, plusEquals, plusTimes, plusTimesEquals, projection, randomNormalizedVector, rotate90Equals, set, setZero, shortValue, times, times, timesEquals, timesTranspose, timesTranspose, toString, toStringNoWhitespace, transposeTimes, transposeTimes, transposeTimesTimes, unitVectorprivate BitSet dims
public ProjectedCentroid(BitSet dims, int dim)
dims - Dimensions to use (indexed with 0)dim - Full dimensionalitypublic void put(double[] val)
public void put(double[] val,
       double weight)
public void put(NumberVector<?> val)
public void put(NumberVector<?> val, double weight)
public static ProjectedCentroid make(BitSet dims, Relation<? extends NumberVector<?>> relation)
dims - Dimensions to use (indexed with 0)relation - Relation to processpublic static ProjectedCentroid make(BitSet dims, Relation<? extends NumberVector<?>> relation, DBIDs ids)
dims - Dimensions to use (indexed with 0)relation - Relation to processids - IDs to process