Package dev.nm.stat.test.distribution
Class CramerVonMises2Samples
- java.lang.Object
-
- dev.nm.stat.test.HypothesisTest
-
- dev.nm.stat.test.distribution.CramerVonMises2Samples
-
public class CramerVonMises2Samples extends HypothesisTest
This algorithm calculates the two sample Cramer-Von Mises test statistic and p-value. The p-value is approximated by linear interpolation.- See Also:
- "Anderson, T. W., "On the distribution of the two Sample Cramer-von Mises Criterion", The Annals of Mathematical Statistics, Vol. 33, No. 3, Sep. 1962, pp. 1148-1159."
- "Anderson, T. W., Darling, D. A. "Asymptotic Theory of Certain "Goodness of Fit" Criteria based on Stochastic Processes", The Annals of Mathematical Statistics, Col.23, No.2, Jun., 1952, pp 193-212."
-
-
Constructor Summary
Constructors Constructor Description CramerVonMises2Samples(double[] x1, double[] x2)
Calculate the statistics and p-value of two sample Cramer-Von Mises test.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getAlternativeHypothesis()
Get the description of the alternative hypothesis.String
getNullHypothesis()
Get a description of the null hypothesis.double
pValue()
Get the p-value for the test statistics.double
statistics()
Get the test statistics.-
Methods inherited from class dev.nm.stat.test.HypothesisTest
isNullRejected, nGroups, nObs, oneSidedPvalue
-
-
-
-
Method Detail
-
statistics
public double statistics()
Description copied from class:HypothesisTest
Get the test statistics.- Specified by:
statistics
in classHypothesisTest
- Returns:
- the test statistics
- See Also:
- Wikipedia: Test statistic
-
pValue
public double pValue()
Description copied from class:HypothesisTest
Get the p-value for the test statistics.- Specified by:
pValue
in classHypothesisTest
- Returns:
- the p-value
- See Also:
- Wikipedia: P-value
-
getAlternativeHypothesis
public String getAlternativeHypothesis()
Description copied from class:HypothesisTest
Get the description of the alternative hypothesis.- Specified by:
getAlternativeHypothesis
in classHypothesisTest
- Returns:
- the alternative hypothesis description
- See Also:
- Wikipedia: Alternative hypothesis
-
getNullHypothesis
public String getNullHypothesis()
Description copied from class:HypothesisTest
Get a description of the null hypothesis.- Specified by:
getNullHypothesis
in classHypothesisTest
- Returns:
- the null hypothesis description
- See Also:
- Wikipedia: Null hypothesis
-
-