InputType
- Type of data upon which the KNearestNeighbor operates,
something like Vector, Double, or StringOutputType
- Output of the evaluator, like Matrix, Double, Stringpublic abstract class AbstractNearestNeighbor<InputType,OutputType> extends DefaultDivergenceFunctionContainer<InputType,InputType> implements NearestNeighbor<InputType,OutputType>
divergenceFunction
Constructor and Description |
---|
AbstractNearestNeighbor()
Creates a new instance of AbstractNearestNeighbor
|
AbstractNearestNeighbor(DivergenceFunction<? super InputType,? super InputType> divergenceFunction)
Creates a new instance of AbstractNearestNeighbor
|
Modifier and Type | Method and Description |
---|---|
void |
add(InputOutputPair<? extends InputType,OutputType> value)
Adds the Pair to the data.
|
clone, getDivergenceFunction, setDivergenceFunction
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getData, getDivergenceFunction
clone
public AbstractNearestNeighbor()
public AbstractNearestNeighbor(DivergenceFunction<? super InputType,? super InputType> divergenceFunction)
divergenceFunction
- The internal divergence function for the object to use.public void add(InputOutputPair<? extends InputType,OutputType> value)
NearestNeighbor
add
in interface NearestNeighbor<InputType,OutputType>
value
- Value to add to the data.