com.threerings.probs
Class FloatVariable

java.lang.Object
  extended by com.threerings.util.DeepObject
      extended by com.threerings.probs.FloatVariable
All Implemented Interfaces:
Exportable, Copyable, Cloneable
Direct Known Subclasses:
FloatVariable.Constant, FloatVariable.Exponential, FloatVariable.Normal, FloatVariable.Uniform

@EditorTypes(value={FloatVariable.Constant.class,FloatVariable.Uniform.class,FloatVariable.Normal.class,FloatVariable.Exponential.class},
             label="distribution")
public abstract class FloatVariable
extends DeepObject
implements Exportable

A floating point random variable.


Nested Class Summary
static class FloatVariable.Constant
          Always returns the same value.
static class FloatVariable.Exponential
          Returns an exponentially distributed value.
static class FloatVariable.Normal
          Returns a normally distributed value.
static class FloatVariable.Uniform
          Returns a uniformly distributed value.
 
Constructor Summary
FloatVariable()
           
 
Method Summary
abstract  float getMean()
          Returns the variable's mean.
abstract  float getValue()
          Returns a sample value according to the variable's distribution.
 
Methods inherited from class com.threerings.util.DeepObject
clone, copy, copy, equals, hashCode, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FloatVariable

public FloatVariable()
Method Detail

getValue

public abstract float getValue()
Returns a sample value according to the variable's distribution.


getMean

public abstract float getMean()
Returns the variable's mean.



Copyright © 2011. All Rights Reserved.