Performs permutation ANOVA for any number of factors.

permutation_anova(df, factors, response, n = 1000, seed = 123, ci = 0.95)

Arguments

df

Data frame or tibble.

factors

Character vector of factor names.

response

Response variable.

n

Number of permutations.

seed

Random seed.

ci

Confidence level for null distribution (default 0.95).

Value

A tibble with:

observed_statistic

Observed F-statistics.

permutations

List of permuted F-statistics.

p_value

Permutation p-values for each factor/interaction.

ci_low

Lower bound of confidence interval.

ci_high

Upper bound of confidence interval.