Class WilcoxonSignedRankTest.Result
java.lang.Object
org.apache.commons.statistics.inference.WilcoxonSignedRankTest.Result
- All Implemented Interfaces:
SignificanceResult
- Enclosing class:
WilcoxonSignedRankTest
Result for the Wilcoxon signed-rank test.
This class is immutable.
- Since:
- 1.1
-
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the test statistic p-value.doubleReturns the test statistic.booleanReturntrueif the data had tied values (with equal ranks).booleanReturntrueif the data had zero values.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.commons.statistics.inference.SignificanceResult
reject
-
Method Details
-
hasTiedValues
Returntrueif the data had tied values (with equal ranks).Note: The exact computation cannot be used when there are tied values. The p-value uses the asymptotic approximation using a tie correction.
- Returns:
trueif there were tied values
-
hasZeroValues
Returntrueif the data had zero values. This occurs when the differences between sample values matched the expected location shift:z = x - y == mu.Note: The exact computation cannot be used when there are zero values. The p-value uses the asymptotic approximation.
- Returns:
trueif there were zero values
-
getStatistic
public double getStatistic()Description copied from interface:SignificanceResultReturns the test statistic.- Specified by:
getStatisticin interfaceSignificanceResult- Returns:
- the statistic
-
getPValue
public double getPValue()Description copied from interface:SignificanceResultReturns the test statistic p-value.The number returned is the smallest significance level at which one can reject the null hypothesis.
- Specified by:
getPValuein interfaceSignificanceResult- Returns:
- the p-value
-