wsrtestrss {RSSampling} | R Documentation |
Wilcoxon signed rank test with RSS
Description
It performs the RSS version of the Wilcoxon signed rank test given by Chen et. al.(2003).
Usage
wsrtestrss(sampledata,m,r,delta0=0,alpha=0.05,alternative="two.sided")
Arguments
sampledata |
An obtained ranked set sample |
m |
Number of units in each set (set size) |
r |
Number of cycles |
delta0 |
The median value of difference in the null hypothesis |
alpha |
The significance level (by default = 0.05). |
alternative |
Character string defining the alternative hypothesis, one of "two.sided", "less" or "greater" (by default = "two.sided") |
Details
The test statistics and an approximate confidence intervals are constructed by using the normal approximation. Also note that, we assume that the ranking mechanism in the RSS is consistent. For more details please refer to Chen et. al.(2003, pg. 124-133).
Value
median |
median value of the sample |
sign.rank.test.stat |
The value of the Wilcoxon signed rank test statistic |
z.test |
the z statistic for test |
p.value |
the p value for the test |
References
Chen, Z., Bai Z., Sinha B. K. (2003). Ranked Set Sampling: Theory and Application. New York: Springer.
Examples
library("LearnBayes")
mu=c(1,1.2,2)
Sigma <- matrix(c(1,2,0,2,5,0.5,0,0.5,3), 3, 3)
x <- rmnorm(10000, mu, Sigma)
xx=as.numeric(x[,1])
xy=as.numeric(x[,2])
samplerss=con.rss(xx,xy,m=3,r=12,concomitant=TRUE)
sample.x=as.numeric(samplerss$sample.x)
sample.y=as.numeric(samplerss$sample.y)
difference=sample.x-sample.y
wsrtestrss(difference,m=3,r=12,delta0=0)