Skip to contents

Performs Fisher's exact test comparing each group to a reference group, modified based on rstatix pairwise implementation

Usage

many_to_one_fisher_test(
  xtab,
  ref.group = NULL,
  p.adjust.method = "holm",
  detailed = FALSE,
  ...
)

Arguments

xtab

A contingency table as a matrix or data frame

ref.group

Character string specifying the reference group (must match one of the row names in xtab)

p.adjust.method

Method for adjusting p-values for multiple comparisons

detailed

Logical indicating whether to return detailed results

...

Additional arguments passed to fisher.test()

Value

A data frame containing the results of the Fisher's exact tests

Examples

if (FALSE) { # \dontrun{
# Create contingency table
ctable <- create_contingency_table(data)
# Run many-to-one Fisher's test with dose_0 as reference
many_to_one_fisher_test(ctable, ref.group = "dose_0")
} # }