Learn R Programming

PMCMR (version 4.3)

posthoc.vanWaerden.test: Pairwise Test for Multiple Comparisons of normal scores (van der Waerden test)

Description

Calculate pairwise multiple comparisons between group levels according to van der Waerden.

Usage

posthoc.vanWaerden.test(x, …)

# S3 method for default posthoc.vanWaerden.test( x, g, p.adjust.method = p.adjust.methods, …)

# S3 method for formula posthoc.vanWaerden.test(formula, data, subset, na.action, p.adjust.method = p.adjust.methods, …)

Arguments

x

a numeric vector of data values, or a list of numeric data vectors.

g

a vector or factor object giving the group for the corresponding elements of x. Ignored if x is a list.

formula

a formula of the form response ~ group where response gives the data values and group a vector or factor of the corresponding groups.

data

an optional matrix or data frame (or similar: see model.frame) containing the variables in the formula formula. By default the variables are taken from environment(formula).

subset

an optional vector specifying a subset of observations to be used.

na.action

a function which indicates what should happen when the data contain NAs. Defaults to getOption("na.action").

p.adjust.method

Method for adjusting p values (see p.adjust).

further arguments to be passed to or from methods.

Value

A list with class "PMCMR"

method

The applied method.

data.name

The name of the data.

p.value

The two-sided p-value of the student-t-distribution.

statistic

The estimated quantile of the student-t-distribution.

p.adjust.method

The applied method for p-value adjustment.

%% ...

Details

For one-factorial designs with samples that do not meet the assumptions for one-way-ANOVA and subsequent post-hoc tests, the van der Waerden test vanWaerden.test using normal scores can be employed. Provided that significant differences were detected by this global test, one may be interested in applying post-hoc tests according to van der Waerden for pairwise multiple comparisons of the group levels.

First, the data are ranked according to Kruskal-Wallis. Second, the ranks are transformed to normal scores. The group means of normal scores and the total variance is used to calculate quantiles of the student-t-distribution and consequent p-values.

See vignette("PMCMR") for details.

References

W. J. Conover and R. L. Iman (1979), On multiple-comparisons procedures, Tech. Rep. LA-7677-MS, Los Alamos Scientific Laboratory.

See Also

kruskal.test, vanWaerden.test, posthoc.kruskal.nemenyi.test, posthoc.kruskal.dunn.test, TDist, p.adjust

Examples

Run this code
# NOT RUN {
##
require(stats) 
data(InsectSprays)
attach(InsectSprays)
vanWaerden.test(count, spray)
posthoc.vanWaerden.test(count, spray, "bonferroni")
detach(InsectSprays)
rm(InsectSprays)
# }

Run the code above in your browser using DataLab