cc.mallet.cluster.neighbor_evaluator
Class RandomEvaluator

java.lang.Object
  extended by cc.mallet.cluster.neighbor_evaluator.RandomEvaluator
All Implemented Interfaces:
NeighborEvaluator, java.io.Serializable

public class RandomEvaluator
extends java.lang.Object
implements NeighborEvaluator, java.io.Serializable

Randomly scores Neighbors.

Since:
1.0
Version:
1.0
Author:
"Aron Culotta"
See Also:
NeighborEvaluator, Serialized Form

Constructor Summary
RandomEvaluator(Randoms random)
           
 
Method Summary
 double evaluate(Neighbor neighbor)
           
 double[] evaluate(Neighbor[] neighbors)
           
 void reset()
          Reset the state of the evaluator.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RandomEvaluator

public RandomEvaluator(Randoms random)
Method Detail

evaluate

public double evaluate(Neighbor neighbor)
Specified by:
evaluate in interface NeighborEvaluator
Parameters:
neighbor -
Returns:
A higher score indicates that the modified Clustering is preferred.

evaluate

public double[] evaluate(Neighbor[] neighbors)
Specified by:
evaluate in interface NeighborEvaluator
Parameters:
neighbors -
Returns:
One score per neighbor. A higher score indicates that the modified Clustering is preferred.

reset

public void reset()
Reset the state of the evaluator.

Specified by:
reset in interface NeighborEvaluator