gov.sandia.cognition.learning.data
Class AbstractTargetEstimatePair<TargetType,EstimateType>

java.lang.Object
  extended by gov.sandia.cognition.util.AbstractCloneableSerializable
      extended by gov.sandia.cognition.learning.data.AbstractTargetEstimatePair<TargetType,EstimateType>
Type Parameters:
TargetType - The type of the target (ground-truth).
EstimateType - The type of the estimate (prediction).
All Implemented Interfaces:
TargetEstimatePair<TargetType,EstimateType>, CloneableSerializable, Pair<TargetType,EstimateType>, Serializable, Cloneable
Direct Known Subclasses:
DefaultTargetEstimatePair

public abstract class AbstractTargetEstimatePair<TargetType,EstimateType>
extends AbstractCloneableSerializable
implements TargetEstimatePair<TargetType,EstimateType>

An abstract implementation of the TargetEstimatePair. This is useful when keeping track of both a target (ground-truth) and an estimate (prediction), for example when estimating the performance of a function.

Since:
3.1
Author:
Justin Basilico, Kevin R. Dixon
See Also:
Serialized Form

Constructor Summary
AbstractTargetEstimatePair()
          Creates a new AbstractTargetEstimatePair.
 
Method Summary
 TargetType getFirst()
          Gets the target, which is the first element in the pair.
 EstimateType getSecond()
          Gets the estimate, which is the second element in the pair.
 String toString()
           
 
Methods inherited from class gov.sandia.cognition.util.AbstractCloneableSerializable
clone
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface gov.sandia.cognition.learning.data.TargetEstimatePair
getEstimate, getTarget
 

Constructor Detail

AbstractTargetEstimatePair

public AbstractTargetEstimatePair()
Creates a new AbstractTargetEstimatePair.

Method Detail

getFirst

public TargetType getFirst()
Gets the target, which is the first element in the pair.

Specified by:
getFirst in interface Pair<TargetType,EstimateType>
Returns:
The target.

getSecond

public EstimateType getSecond()
Gets the estimate, which is the second element in the pair.

Specified by:
getSecond in interface Pair<TargetType,EstimateType>
Returns:
The estimate.

toString

public String toString()
Overrides:
toString in class Object