Skip to contents

A list containing results from a multi-sample test.

Usage

k_sample(
  data,
  x,
  y,
  rowid = NULL,
  type,
  paired = FALSE,
  var.equal = FALSE,
  is_spherical = NULL,
  adjust = NULL,
  effsize.type = "unbiased",
  conf.level = 0.95,
  character.only = FALSE,
  ...
)

Arguments

data

Data frame from which x and y (and possibly rowid if provided) will be searched.

x

Character for the grouping factor. Must be present in data

y

Character for the response variable. Must be present in data.

rowid

Character for the subject-id column. If null, then is assumed that data is sorted for paired designs, creating one. So if your data is not sorted and you leave this argument unspecified, the results can be inaccurate when there are more than two levels in x and there are NAs present.

type

Missing (default) or NULL for checking the normality and homogeneity of variances for test selection. Other options are "p" for parametric, "np" for non-parametric and "r" for robust tests.

paired

Logical that decides whether the experimental design is repeated measures/within-subjects or between-subjects. The default is FALSE.

var.equal

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.

is_spherical

Logical. checks whether to assume that the sphericity assumptions holds or not, if NULL (the default) it will be tested using mauchly's test with a threshold of 0.05.

adjust

Character. correction for sphericity to be applied, it can be any character of length one starting with 'g' (indicating Greenhouse–Geisser correction) or 'h' (indicating Huynh–Feldt correction).

effsize.type

Options are "unbiased" or "omega" for partial omega squared and "biased" or "eta" for partial eta squared as a measure of effect size. For non-parametric analysis, Kendalls' W is used for paired designs, where rank epsilon squared is used for independent groups designs.

conf.level

Confidence/Credible Interval (CI) level. Default to 0.95 (95%).

character.only

Logical. checks whether to use the unevaluated expression or its content (when TRUE), asumming is a character vector. Defaults to FALSE.

...

Currently ignored.