|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.lmu.ifi.dbs.elki.algorithm.outlier.spatial.neighborhood.weighted.LinearWeightedExtendedNeighborhood
public class LinearWeightedExtendedNeighborhood
Neighborhood obtained by computing the k-fold closure of an existing neighborhood. Objects are weighted linearly by their distance: the object itself has a weight of 1 and this decreases linearly to 1/(n+1) for the nth-step neighbors. TODO: make actual weighting parameterizable?
Nested Class Summary | |
---|---|
static class |
LinearWeightedExtendedNeighborhood.Factory<O>
Factory class. |
Field Summary | |
---|---|
private NeighborSetPredicate |
inner
The data store to use |
private int |
steps
The number of steps to extend to. |
Constructor Summary | |
---|---|
LinearWeightedExtendedNeighborhood(NeighborSetPredicate inner,
int steps)
Constructor. |
Method Summary | |
---|---|
private double |
computeWeight(int tsteps)
Compute the weight from the number of steps needed. |
Collection<DoubleObjPair<DBID>> |
getWeightedNeighbors(DBID reference)
Get the neighbors of a reference object for DBSCAN. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private NeighborSetPredicate inner
private int steps
Constructor Detail |
---|
public LinearWeightedExtendedNeighborhood(NeighborSetPredicate inner, int steps)
inner
- Inner neighborhoodsteps
- Number of steps to expandMethod Detail |
---|
private double computeWeight(int tsteps)
tsteps
- steps to target
public Collection<DoubleObjPair<DBID>> getWeightedNeighbors(DBID reference)
WeightedNeighborSetPredicate
getWeightedNeighbors
in interface WeightedNeighborSetPredicate
reference
- Reference object
|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |