public class DiscreteArcsineDistribution extends Distribution implements java.io.Serializable
CONTINUOUS, DISCRETE, MIXED
Constructor and Description |
---|
DiscreteArcsineDistribution()
This default constructor creates a new discrete arcsine distribution with 10 steps.
|
DiscreteArcsineDistribution(int n)
This general constructor creates a new discrete arcsine distribution with a
specified number of steps.
|
Modifier and Type | Method and Description |
---|---|
double |
getDensity(double x)
This method computes the probability density function.
|
double |
getMaxDensity()
This method computes the maximum value of the density function.
|
double |
getMean()
This method computes the mean of the distribution.
|
int |
getSteps()
This method gets the steps, the number of steps.
|
void |
setSteps(int n)
This method sets the steps, the number of steps, and then defines the default
domain.
|
double |
simulate()
This method simulates a value from the distribution, by simulating a random walk
on the interval and computing the time of the last zero.
|
java.lang.String |
toString()
This method returns a string that gives the name of the distribution and the values of
the parameters.
|
getCDF, getDomain, getFailureRate, getMedian, getMGF, getMoment, getMoment, getPGF, getQuantile, getSD, getType, getVariance, setDomain, setDomain
public DiscreteArcsineDistribution(int n)
n
- the number of stepspublic DiscreteArcsineDistribution()
public void setSteps(int n)
n
- the number of stepspublic double getDensity(double x)
getDensity
in class Distribution
x
- a number in the domain of the distributionpublic double getMaxDensity()
getMaxDensity
in class Distribution
public int getSteps()
public double getMean()
getMean
in class Distribution
public double simulate()
simulate
in class Distribution
public java.lang.String toString()
toString
in class Distribution