| java.lang.Object org.apache.commons.math.distribution.AbstractDistribution org.apache.commons.math.distribution.AbstractIntegerDistribution org.apache.commons.math.distribution.HypergeometricDistributionImpl
Constructor Summary | |
public | HypergeometricDistributionImpl(int populationSize, int numberOfSuccesses, int sampleSize) Construct a new hypergeometric distribution with the given the population
size, the number of successes in the population, and the sample size. |
Method Summary | |
public double | cumulativeProbability(int x) For this disbution, X, this method returns P(X ≤ x).
Parameters: x - the value at which the PDF is evaluated. | protected int | getDomainLowerBound(double p) Access the domain value lower bound, based on p , used to
bracket a PDF root. | protected int | getDomainUpperBound(double p) Access the domain value upper bound, based on p , used to
bracket a PDF root. | public int | getNumberOfSuccesses() Access the number of successes. | public int | getPopulationSize() Access the population size. | public int | getSampleSize() Access the sample size. | public double | probability(int x) For this disbution, X, this method returns P(X = x).
Parameters: x - the value at which the PMF is evaluated. | public void | setNumberOfSuccesses(int num) Modify the number of successes. | public void | setPopulationSize(int size) Modify the population size. | public void | setSampleSize(int size) Modify the sample size. | public double | upperCumulativeProbability(int x) For this disbution, X, this method returns P(X ≥ x).
Parameters: x - the value at which the CDF is evaluated. |
HypergeometricDistributionImpl | public HypergeometricDistributionImpl(int populationSize, int numberOfSuccesses, int sampleSize)(Code) | | Construct a new hypergeometric distribution with the given the population
size, the number of successes in the population, and the sample size.
Parameters: populationSize - the population size. Parameters: numberOfSuccesses - number of successes in the population. Parameters: sampleSize - the sample size. |
cumulativeProbability | public double cumulativeProbability(int x)(Code) | | For this disbution, X, this method returns P(X ≤ x).
Parameters: x - the value at which the PDF is evaluated. PDF for this distribution. |
getDomainLowerBound | protected int getDomainLowerBound(double p)(Code) | | Access the domain value lower bound, based on p , used to
bracket a PDF root.
Parameters: p - the desired probability for the critical value domain value lower bound, i.e.P(X < lower bound) < p |
getDomainUpperBound | protected int getDomainUpperBound(double p)(Code) | | Access the domain value upper bound, based on p , used to
bracket a PDF root.
Parameters: p - the desired probability for the critical value domain value upper bound, i.e.P(X < upper bound) > p |
getNumberOfSuccesses | public int getNumberOfSuccesses()(Code) | | Access the number of successes.
the number of successes. |
getPopulationSize | public int getPopulationSize()(Code) | | Access the population size.
the population size. |
getSampleSize | public int getSampleSize()(Code) | | Access the sample size.
the sample size. |
probability | public double probability(int x)(Code) | | For this disbution, X, this method returns P(X = x).
Parameters: x - the value at which the PMF is evaluated. PMF for this distribution. |
setNumberOfSuccesses | public void setNumberOfSuccesses(int num)(Code) | | Modify the number of successes.
Parameters: num - the new number of successes. throws: IllegalArgumentException - if num is negative. |
setPopulationSize | public void setPopulationSize(int size)(Code) | | Modify the population size.
Parameters: size - the new population size. throws: IllegalArgumentException - if size is not positive. |
setSampleSize | public void setSampleSize(int size)(Code) | | Modify the sample size.
Parameters: size - the new sample size. throws: IllegalArgumentException - if size is negative. |
upperCumulativeProbability | public double upperCumulativeProbability(int x)(Code) | | For this disbution, X, this method returns P(X ≥ x).
Parameters: x - the value at which the CDF is evaluated. upper tail CDF for this distribution. since: 1.1 |
Methods inherited from org.apache.commons.math.distribution.AbstractDistribution | public double cumulativeProbability(double x0, double x1) throws MathException(Code)(Java Doc)
|
|
|