org.statcato.statistics.inferential.nonparametrics
Class WilcoxonSignedRankTest
- java.lang.Object
-
- org.statcato.statistics.inferential.nonparametrics.WilcoxonSignedRankTest
-
public class WilcoxonSignedRankTest extends java.lang.ObjectWilcoxon Signed Rank test. A nonparametic test for claims regarding the median of a single population. Samples are ranked by their absolute distances from the hypothesized median. The ranks of sample values that are above the hypothesized median are given positive signs; those of values below the hypothesized median are given negative signs. The sums of the ranks corresponding to positive and negative signs are computed, respectively. The rank sums are used as test statistics.- Since:
- 1.0
-
-
Field Summary
Fields Modifier and Type Field and Description static intGREATERAlternative hypothesis type: greater thanstatic intLESSAlternative hypothesis type: less thanstatic intNOTEQUALAlternative hypothesis type: not equal todoublesignificanceSignificance of the test.
-
Constructor Summary
Constructors Constructor and Description WilcoxonSignedRankTest(java.util.Vector<java.lang.Double> data, double testMedian, int testType, double significance)Constructor, given data values.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description doublegetRankSum(java.util.Vector<java.lang.Double> data)Returns the rank sum of the given data (negative rank sum for right-tailed test, positive rank sum for left-tailed, and minimum of the two rank sums for two-tailed).doublepValue()Returns the p-value.java.lang.StringtoString()
-
-
-
Field Detail
-
LESS
public static int LESS
Alternative hypothesis type: less than
-
GREATER
public static int GREATER
Alternative hypothesis type: greater than
-
NOTEQUAL
public static int NOTEQUAL
Alternative hypothesis type: not equal to
-
significance
public double significance
Significance of the test.
-
-
Constructor Detail
-
WilcoxonSignedRankTest
public WilcoxonSignedRankTest(java.util.Vector<java.lang.Double> data, double testMedian, int testType, double significance)Constructor, given data values.- Parameters:
data- vector of double valuestestMedian- hypothesized mediantestType- type of alternative hypothesis
-
-
Method Detail
-
pValue
public double pValue()
Returns the p-value.- Returns:
- p-value
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
getRankSum
public double getRankSum(java.util.Vector<java.lang.Double> data)
Returns the rank sum of the given data (negative rank sum for right-tailed test, positive rank sum for left-tailed, and minimum of the two rank sums for two-tailed).- Parameters:
data- vector of Double values- Returns:
- rank sum
-
-
DMelt 3.0 © DataMelt by jWork.ORG