Learn R Programming

RVAideMemoire (version 0.9-35)

pairwise.perm.t.test: Pairwise permutational t tests

Description

Perform pairwise comparisons between group levels with corrections for multiple testing.

Usage

pairwise.perm.t.test(resp, fact, p.method = "fdr", paired = FALSE,
  alternative = c("two.sided","less", "greater"), nperm = 999)

Arguments

resp
response vector.
fact
grouping factor.
p.method
method for p-values correction. See help of p.adjust.
paired
a logical indicating whether you want paired (permutational) t-tests.
alternative
a character string specifying the alternative hypothesis, must be one of "two.sided" (default), "greater" or "less".
nperm
number of permutations.

Value

  • methoda character string indicating what type of t-tests were performed.
  • data.namea character string giving the name(s) of the data.
  • p.valuetable of results.
  • p.adjust.methodmethod for p-values correction.
  • permutationsnumber of permutations.

See Also

pairwise.t.test

Examples

Run this code
set.seed(1203)
response <- c(rnorm(5),rpois(5,0.5),rnorm(5,2,1))
fact <- gl(3,5,labels=LETTERS[1:3])

# Not enough permutations here but it runs faster

# Permutational ANOVA
perm.anova(response~fact,nperm=49)

# Pairwise comparisons
pairwise.perm.t.test(response,fact,nperm=49)

Run the code above in your browser using DataLab