|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.mahout.math.function.DoubleFunction
org.apache.mahout.math.jet.random.AbstractDistribution
public abstract class AbstractDistribution
Constructor Summary | |
---|---|
protected |
AbstractDistribution()
Makes this class non instantiable, but still let's others inherit from it. |
Method Summary | |
---|---|
double |
apply(double dummy)
Equivalent to nextDouble(). |
int |
apply(int dummy)
Equivalent to nextInt(). |
protected Random |
getRandomGenerator()
|
abstract double |
nextDouble()
Returns a random number from the distribution. |
abstract int |
nextInt()
|
protected double |
randomDouble()
|
void |
setRandomGenerator(Random randomGenerator)
Sets the uniform random generator internally used. |
Methods inherited from class org.apache.mahout.math.function.DoubleFunction |
---|
isDensifying |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected AbstractDistribution()
Method Detail |
---|
protected Random getRandomGenerator()
protected double randomDouble()
public double apply(double dummy)
apply
in class DoubleFunction
dummy
- double for the argument
public int apply(int dummy)
apply
in interface IntFunction
dummy
- argument passed to the function.
public abstract double nextDouble()
public abstract int nextInt()
public void setRandomGenerator(Random randomGenerator)
randomGenerator
- the new PRNG
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |