javanpst.tests.oneSample.confidenceQuantile
Class ConfidenceQuantile
- java.lang.Object
-
- javanpst.tests.StatisticalTest
-
- javanpst.tests.oneSample.confidenceQuantile.ConfidenceQuantile
-
public class ConfidenceQuantile extends StatisticalTest
A test for estimating population quantiles. This test estimates a population quantile providing a confidence interval as closer as possible. It does Two confidence intervals are provided: an exact version, using the Binomial distribution, and an approximate interval, using the Normal distribution.
-
-
Constructor Summary
Constructors Constructor and Description ConfidenceQuantile()Default builderConfidenceQuantile(int n, double p, double confidence)Builder.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidclearData()Clears the data stored in the testvoiddoTest()Performs the testdoublegetApproximateLowerLimit()Get lower limit of the approximate confidence intervaldoublegetApproximateUpperLimit()Get upper limit of the approximate confidence intervaldoublegetExactLowerLimit()Get lower limit of the exact confidence intervaldoublegetExactUpperLimit()Get upper limit of the exact confidence intervaljava.lang.StringprintData()Prints the data stored in the testjava.lang.StringprintReport()Prints a report with the results of the testvoidsetConfidence(double c)Set confidence desiredvoidsetQuantile(double p)Set quantile to estimatevoidsetSampleSize(int n)Set sample size-
Methods inherited from class javanpst.tests.StatisticalTest
isDataReady, isPerformed
-
-
-
-
Constructor Detail
-
ConfidenceQuantile
public ConfidenceQuantile()
Default builder
-
ConfidenceQuantile
public ConfidenceQuantile(int n, double p, double confidence)Builder. Set all the necessary parameters of the test.- Parameters:
n- sample sizep- quantile to estimateconfidence- confidence level desired
-
-
Method Detail
-
clearData
public void clearData()
Clears the data stored in the test- Specified by:
clearDatain classStatisticalTest
-
setSampleSize
public void setSampleSize(int n)
Set sample size- Parameters:
n- new sample size
-
setQuantile
public void setQuantile(double p)
Set quantile to estimate- Parameters:
p- quantile
-
setConfidence
public void setConfidence(double c)
Set confidence desired- Parameters:
c- confidence level
-
doTest
public void doTest()
Performs the test- Specified by:
doTestin classStatisticalTest
-
getExactLowerLimit
public double getExactLowerLimit()
Get lower limit of the exact confidence interval- Returns:
- exact lower limit. NaN if the limit is -INFINITE
-
getExactUpperLimit
public double getExactUpperLimit()
Get upper limit of the exact confidence interval- Returns:
- exact upper limit. NaN if the limit is +INFINITE
-
getApproximateLowerLimit
public double getApproximateLowerLimit()
Get lower limit of the approximate confidence interval- Returns:
- approximate lower limit. NaN if the limit is -INFINITE
-
getApproximateUpperLimit
public double getApproximateUpperLimit()
Get upper limit of the approximate confidence interval- Returns:
- approximate upper limit. NaN if the limit is +INFINITE
-
printData
public java.lang.String printData()
Prints the data stored in the test- Specified by:
printDatain classStatisticalTest- Returns:
- Data stored
-
printReport
public java.lang.String printReport()
Prints a report with the results of the test- Specified by:
printReportin classStatisticalTest- Returns:
- Output report
-
-
DMelt 3.0 © DataMelt by jWork.ORG