Package elki.evaluation.scores.adapter
Class IncreasingVectorIter
- java.lang.Object
-
- elki.evaluation.scores.adapter.AbstractVectorIter
-
- elki.evaluation.scores.adapter.IncreasingVectorIter
-
- All Implemented Interfaces:
ScoreEvaluation.Adapter,ArrayIter,Iter,it.unimi.dsi.fastutil.ints.IntComparator,java.util.Comparator<java.lang.Integer>
public class IncreasingVectorIter extends AbstractVectorIter implements it.unimi.dsi.fastutil.ints.IntComparator
Class to iterate over a number vector in decreasing order.- Since:
- 0.7.0
- Author:
- Erich Schubert
-
-
Field Summary
-
Fields inherited from class elki.evaluation.scores.adapter.AbstractVectorIter
numPositive, pos, positive, sort, vec
-
-
Constructor Summary
Constructors Constructor Description IncreasingVectorIter(NumberVector positive, NumberVector vec)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IncreasingVectorIteradvance(int count)Moves the iterator forward or backward by the given offset.intcompare(int x, int y)IncreasingVectorIterretract()Moves the iterator backward to the previous entry.IncreasingVectorIterseek(int off)Moves the iterator to the given position-
Methods inherited from class elki.evaluation.scores.adapter.AbstractVectorIter
advance, dim, getOffset, numPositive, numTotal, test, tiedToPrevious, valid
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
-
-
Constructor Detail
-
IncreasingVectorIter
public IncreasingVectorIter(NumberVector positive, NumberVector vec)
Constructor.- Parameters:
positive- Vector of positive valuesvec- Vector to iterate over.
-
-
Method Detail
-
compare
public int compare(int x, int y)- Specified by:
comparein interfaceit.unimi.dsi.fastutil.ints.IntComparator
-
advance
public IncreasingVectorIter advance(int count)
Description copied from interface:ArrayIterMoves the iterator forward or backward by the given offset.- Specified by:
advancein interfaceArrayIter- Overrides:
advancein classAbstractVectorIter- Parameters:
count- offset to move forward or backwards- Returns:
- Iterator
-
retract
public IncreasingVectorIter retract()
Description copied from interface:ArrayIterMoves the iterator backward to the previous entry.- Specified by:
retractin interfaceArrayIter- Overrides:
retractin classAbstractVectorIter- Returns:
- Iterator
-
seek
public IncreasingVectorIter seek(int off)
Description copied from interface:ArrayIterMoves the iterator to the given position- Specified by:
seekin interfaceArrayIter- Overrides:
seekin classAbstractVectorIter- Parameters:
off- Seek offset- Returns:
- Iterator
-
-