V
- the type of NumberVector this unit containspublic class CLIQUEUnit<V extends NumberVector> extends Object
Modifier and Type | Field and Description |
---|---|
private boolean |
assigned
Flag that indicates if this unit is already assigned to a cluster.
|
private ModifiableDBIDs |
ids
The ids of the feature vectors this unit contains.
|
private ArrayList<CLIQUEInterval> |
intervals
The one-dimensional intervals of which this unit is build.
|
Modifier | Constructor and Description |
---|---|
private |
CLIQUEUnit(ArrayList<CLIQUEInterval> intervals,
ModifiableDBIDs ids)
Creates a new k-dimensional unit for the given intervals.
|
|
CLIQUEUnit(CLIQUEInterval interval)
Creates a new one-dimensional unit for the given interval.
|
Modifier and Type | Method and Description |
---|---|
boolean |
addFeatureVector(DBIDRef id,
V vector)
Adds the id of the specified feature vector to this unit, if this unit
contains the feature vector.
|
boolean |
contains(V vector)
Returns true, if the intervals of this unit contain the specified feature
vector.
|
boolean |
containsLeftNeighbor(CLIQUEInterval i)
Returns true if this unit contains the left neighbor of the specified
interval.
|
boolean |
containsRightNeighbor(CLIQUEInterval i)
Returns true if this unit contains the right neighbor of the specified
interval.
|
DBIDs |
getIds()
Returns the ids of the feature vectors this unit contains.
|
CLIQUEInterval |
getInterval(int dimension)
Returns the interval of the specified dimension.
|
ArrayList<CLIQUEInterval> |
getIntervals()
Returns a sorted set of the intervals of which this unit is build.
|
boolean |
isAssigned()
Returns true if this unit is already assigned to a cluster.
|
CLIQUEUnit<V> |
join(CLIQUEUnit<V> other,
double all,
double tau)
Joins this unit with the specified unit.
|
void |
markAsAssigned()
Marks this unit as assigned to a cluster.
|
int |
numberOfFeatureVectors()
Returns the number of feature vectors this unit contains.
|
double |
selectivity(double total)
Returns the selectivity of this unit, which is defined as the fraction of
total feature vectors contained in this unit.
|
String |
toString()
Returns a string representation of this unit that contains the intervals of
this unit.
|
private ArrayList<CLIQUEInterval> intervals
private ModifiableDBIDs ids
private boolean assigned
private CLIQUEUnit(ArrayList<CLIQUEInterval> intervals, ModifiableDBIDs ids)
intervals
- the intervals belonging to this unitids
- the ids of the feature vectors belonging to this unitpublic CLIQUEUnit(CLIQUEInterval interval)
interval
- the interval belonging to this unitpublic boolean contains(V vector)
vector
- the feature vector to be tested for containmentpublic boolean addFeatureVector(DBIDRef id, V vector)
id
- Vector idvector
- the feature vector to be addedpublic int numberOfFeatureVectors()
public double selectivity(double total)
total
- the total number of feature vectorspublic ArrayList<CLIQUEInterval> getIntervals()
public CLIQUEInterval getInterval(int dimension)
dimension
- the dimension of the interval to be returnedpublic boolean containsLeftNeighbor(CLIQUEInterval i)
i
- the intervalpublic boolean containsRightNeighbor(CLIQUEInterval i)
i
- the intervalpublic boolean isAssigned()
public void markAsAssigned()
public DBIDs getIds()
public CLIQUEUnit<V> join(CLIQUEUnit<V> other, double all, double tau)
other
- the unit to be joinedall
- the overall number of feature vectorstau
- the density threshold for the selectivity of a unitCopyright © 2015 ELKI Development Team, Lehr- und Forschungseinheit für Datenbanksysteme, Ludwig-Maximilians-Universität München. License information.