gov.sandia.cognition.statistics
Class AbstractRandomVariable<DataType>

java.lang.Object
  extended by gov.sandia.cognition.util.AbstractCloneableSerializable
      extended by gov.sandia.cognition.math.AbstractRing<RandomVariable<DataType>>
          extended by gov.sandia.cognition.statistics.AbstractRandomVariable<DataType>
Type Parameters:
DataType - Type of data that can be sampled from the Distribution.
All Implemented Interfaces:
Ring<RandomVariable<DataType>>, Distribution<DataType>, RandomVariable<DataType>, CloneableSerializable, Randomized, Serializable, Cloneable
Direct Known Subclasses:
UnivariateRandomVariable

public abstract class AbstractRandomVariable<DataType>
extends AbstractRing<RandomVariable<DataType>>
implements RandomVariable<DataType>, Randomized

Partial implementation of RandomVariable.

Since:
3.0
Author:
Kevin R. Dixon
See Also:
Serialized Form

Constructor Summary
AbstractRandomVariable()
           
 
Method Summary
 DataType sample(Random random)
          Draws a single random sample from the distribution.
 
Methods inherited from class gov.sandia.cognition.math.AbstractRing
clone, dotTimes, isZero, minus, negative, negativeEquals, plus, scale, scaledMinus, scaledMinusEquals, scaledPlus, zero
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface gov.sandia.cognition.statistics.Distribution
sample
 
Methods inherited from interface gov.sandia.cognition.math.Ring
clone, dotTimes, dotTimesEquals, equals, equals, isZero, isZero, minus, minusEquals, negative, negativeEquals, plus, plusEquals, scale, scaledMinus, scaledMinusEquals, scaledPlus, scaledPlusEquals, scaleEquals, zero
 
Methods inherited from interface gov.sandia.cognition.util.Randomized
getRandom, setRandom
 

Constructor Detail

AbstractRandomVariable

public AbstractRandomVariable()
Method Detail

sample

public DataType sample(Random random)
Description copied from interface: Distribution
Draws a single random sample from the distribution.

Specified by:
sample in interface Distribution<DataType>
Parameters:
random - Random-number generator to use in order to generate random numbers.
Returns:
Sample drawn according to this distribution.