jhplot.math.num.pdf
Class Uniform
- java.lang.Object
- 
- jhplot.math.num.pdf.ContinuousDistribution
- 
- jhplot.math.num.pdf.Uniform
 
 
- 
- All Implemented Interfaces:
- Distribution
 
 
 public class Uniform extends ContinuousDistribution The Uniform distribution (1). References: - Eric W. Weisstein. "Uniform Distribution." From MathWorld--A Wolfram Web Resource. http://mathworld.wolfram.com/Uniform.html
 - Since:
- 1.1
 
- 
- 
Constructor SummaryConstructors Constructor and Description Uniform()Default constructor.Uniform(double a, double b)Create a distribution with the given lower bound and upper bound values.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method and Description doublecumulativeProbability(double x)The CDF for this distribution.doublegetLower()Access the lower parameter.doublegetUpper()Access the upper parameter.doubleinverseCumulativeProbability(double p)The inverse CDF for this distribution.voidsetLower(double low)Modify the lower bound parameter.voidsetUpper(double up)Modify the upper bound parameter.
 
- 
- 
- 
Constructor Detail- 
Uniformpublic Uniform() Default constructor. The lower bound is set to 0 and the upper bound is set to 1.
 - 
Uniformpublic Uniform(double a, double b)Create a distribution with the given lower bound and upper bound values.- Parameters:
- a- the lower bound parameter.
- b- the upper bound parameter.
 
 
- 
 - 
Method Detail- 
cumulativeProbabilitypublic double cumulativeProbability(double x) The CDF for this distribution. This method returns P(X < x).- Specified by:
- cumulativeProbabilityin class- ContinuousDistribution
- Parameters:
- x- the value at which the CDF is evaluated.
- Returns:
- CDF for this distribution.
 
 - 
getLowerpublic double getLower() Access the lower parameter.- Returns:
- the lower parameter.
 
 - 
getUpperpublic double getUpper() Access the upper parameter.- Returns:
- the upper parameter.
 
 - 
inverseCumulativeProbabilitypublic double inverseCumulativeProbability(double p) The inverse CDF for this distribution. This method returns x such that, P(X < x) = p.- Specified by:
- inverseCumulativeProbabilityin class- ContinuousDistribution
- Parameters:
- p- the cumulative probability.
- Returns:
- x
 
 - 
setLowerpublic void setLower(double low) Modify the lower bound parameter.- Parameters:
- low- the new lower bound value.
 
 - 
setUpperpublic void setUpper(double up) Modify the upper bound parameter.- Parameters:
- up- the new upper bound value.
 
 
- 
 
- 
DMelt 3.0 © DataMelt by jWork.ORG