wilcox.conf: Confidence Functions for the (Pseudo)Median or Shift via...

Description Usage Arguments Value References Examples

View source: R/nonparametric.R

Description

Confidence functions for the (pseudo)median of a continuous distribution via the Wilcoxon signed-rank test (for one sample) or shift between two continuous distributions via the Wilcoxon rank-sum test (for two samples).

Usage

1
wilcox.conf(x, y = NULL, plot = TRUE, conf.level = 0.95)

Arguments

x

a vector of observations for the first sample

y

a vector of observations for the second sample, if applicable

plot

whether to plot the confidence density and curve

conf.level

the confidence level for the confidence interval indicated on the confidence curve

Value

A list containing the confidence functions pconf, dconf, cconf, and qconf for the median, as well as the P-curve and S-curve.

References

Tore Schweder and Nils Lid Hjort. Confidence, likelihood, probability. Vol. 41. Cambridge University Press, 2016.

Myles Hollander, Douglas A. Wolfe, and Eric Chicken. Nonparametric Statistical Methods. Vol. 751. John Wiley & Sons, 2013.

Examples

1
2
3
4
5
6
7
8
9
data(dietstudy)

x <- dietstudy$weightchange[dietstudy$diet == 'Low Carb']
y <- dietstudy$weightchange[dietstudy$diet == 'Low Fat']

lc.wc.conf <- wilcox.conf(x)
lf.wc.conf <- wilcox.conf(y)

comp.wc.conf <- wilcox.conf(x, y)

ddarmon/clp documentation built on Jan. 25, 2021, 6:22 p.m.