robust.t.test: Robustified Student's t-Test

Description Usage Arguments References See Also

View source: R/robust-t-test.R

Description

Performs one and two sample robustified t-tests on vectors of data using ranks or Windsorized data.

Usage

1
2
3
robust.t.test(x, y = NULL, alternative = c("two.sided", "less", "greater"),
  mu = 0, paired = FALSE, var.equal = FALSE, conf.level = 0.95,
  method = c("windsorized", "ranks", "none"), trim = 0.2, ...)

Arguments

x

a (non-empty) numeric vector of data values.

y

an optional (non-empty) numeric vector of data values.

alternative

a character string specifying the alternative hypothesis, must be one of "two.sided" (default), "greater" or "less". You can specify just the initial letter.

mu

a number indicating the true value of the mean (or difference in means if you are performing a two sample test).

paired

(Not availadle, included only for consistency with t.test)

var.equal

a logical variable indicating whether to treat the two variances as being equal. If TRUE then the pooled variance is used to estimate the variance otherwise the Welch (or Satterthwaite) approximation to the degrees of freedom is used.

conf.level

confidence level of the interval.

method

Possible values are "none" for standard t-test, "windsorized" for t-test on Windsorized data, "ranks" for t-test on ranked data.

trim

used only when method = "windsorized"; the fraction (0 to 0.5) of observations to be trimmed from each end of x. Values of trim outside that range are replaced with the nearest endpoint.

References

Keselman, H. J., Algina, J., Lix, L. M., Wilcox, R. R., & Deering, K. (2008). A generally robust approach for testing hypotheses and setting confidence intervals for effect sizes. Psychological Methods, 13, 110<e2><80><93>129.

Winter, J.C.F. (2013). Using the Student<e2><80><99>s t-test with extremely small sample sizes. Practical Assessment, Research and Evaluation, 18:10.

See Also

t.test, windsorize


twolodzko/twextras documentation built on May 3, 2019, 1:52 p.m.