| swilk | R Documentation |
Runs Shapiro-Wilk tests overall, for many variables, and/or within hierarchical groups. Each tested subgroup must have enough complete observations for the Shapiro-Wilk procedure.
swilk(x = NULL,
vars = NULL,
by = NULL,
data = NULL,
digits = 4,
p_digits = 3,
show = TRUE,
console = FALSE)
x |
One numeric variable; may be omitted when |
vars |
Optional |
by |
Optional hierarchical grouping specification. The final variable in |
data |
Data frame; active R4VN data is used when omitted. |
digits, p_digits |
Formatting digits. |
show, console |
R4VN display controls. |
An R4VN result object, invisibly.
normtest, varform
d <- data.frame(x = rnorm(40), y = rnorm(40), group = rep(c("A", "B"), each = 20))
swilk(x, data = d)
swilk(vars = vars(x, y), data = d)
swilk(vars = vars(x, y), by = vars(group), data = d)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.