wilcoxon.signedrank {ANSM5}R Documentation

Perform Wilcoxon signed-rank test

Description

wilcoxon.signedrank() performs the Wilcoxon signed-rank test and is used in chapters 3, 4 and 5 of "Applied Nonparametric Statistical Methods" (5th edition)

Usage

wilcoxon.signedrank(
  x,
  H0 = NULL,
  alternative = c("two.sided", "less", "greater"),
  cont.corr = TRUE,
  CI.width = 0.95,
  max.exact.cases = 1000,
  do.asymp = FALSE,
  do.exact = TRUE,
  do.CI = TRUE
)

Arguments

x

Numeric vector

H0

Null hypothesis value (defaults to NULL)

alternative

Type of alternative hypothesis (defaults to two.sided)

cont.corr

Boolean indicating whether or not to use continuity correction (defaults to TRUE)

CI.width

Confidence interval width (defaults to 0.95)

max.exact.cases

Maximum number of cases allowed for exact calculations (defaults to 1000)

do.asymp

Boolean indicating whether or not to perform asymptotic calculations (defaults to FALSE)

do.exact

Boolean indicating whether or not to perform exact calculations (defaults to TRUE)

do.CI

Boolean indicating whether or not to perform confidence interval calculations (defaults to TRUE)

Value

An ANSMtest object with the results from applying the function

Examples

# Example 3.4 from "Applied Nonparametric Statistical Methods" (5th edition)
wilcoxon.signedrank(ch3$heartrates1, 70, "greater")

# Exercise 5.12 from "Applied Nonparametric Statistical Methods" (5th edition)
wilcoxon.signedrank(ch5$kHz0.125 - ch5$kHz0.25, 0)


[Package ANSM5 version 1.1.0 Index]