# with normal distributions defaults d is standardized
p_wilcox.test(100, .5)
p_wilcox.test(100, .5, type = 'paired') # n = number of pairs
p_wilcox.test(100, .5, type = 'one.sample')
# return analysis object
p_wilcox.test(100, .5, return_analysis = TRUE)
# using chi-squared distributions (standardizing to 0-1)
p_wilcox.test(100, .5, type = 'one.sample',
parent1 = function(n, d) rchisq(n, df=10) - 10 + d)
p_wilcox.test(100, .5,
parent1 = function(n, d) (rchisq(n, df=10) - 10)/sqrt(20) + d,
parent2 = function(n, d) (rchisq(n, df=10) - 10)/sqrt(20))
Run the code above in your browser using DataLab