NPC: NonParametric Combination of Test Statistic

Description Usage Arguments Details Value Note Author(s) References See Also

View source: R/NPC.R

Description

NonParametric Combination of the test statistic matrix, mostly for internal use.

Usage

1
2
3
  NPC(rawStats, combFun = "Fisher", seed, p.values = FALSE,
    tails = NULL, subsets = NULL, weights = NULL,
    iteratedNPC = FALSE)

Arguments

rawStats

3-ways array containing the test statistic computed on all pairwise comparisons (both directions) in all variables, with dimensions B+1 x p x K, where B is the number of permutations, p is the number of variables and K is the number of pairwise comparisons.

combFun

character string indicating the combining function to be used, can take as input p-values or the raw test statistic depending on the choice, can be one of "Fisher", "Liptak", "minP", "Tippett", "maxT", "sumT" and "direct"; note that "direct" is equivalent to "sumT" and "Tippett" is equivalent to "minP". "Liptak" use the normal quantile function. See references for details.

seed

integer seed for the RNG (random number generator), taken from the input for reproducibility purposes

p.values

logical, if TRUE means that the input matrix rawStats contains p-values rather than raw test statistics and so has to be treated differently, i.e. the first passage from test statistics to p-values is omitted (function t2p)

tails

integer vector of {+1,-1} containing the alternatives for response variables: +1 means “the higher the better”, -1 means “the lower the better” (direction of preference), if NULL (default) all variables are considered to be of the type “the higher the better'

subsets

integer, character or list where each element contains the subset of column indices that need to be treated separately, if NULL (default) all input variables are considered

weights

integer, character or list where each element contains the weights of the variables, one for each subset, if NULL (default) variables are treated equally i.e. all have the same weight

iteratedNPC

logical, if TRUE it performs the iterated combination procedure running function iterNPC and the choice of comb.funct becomes thus irrelevant; otherwise just perform the requested NPC.

Details

It takes as input the 3-ways matrix containing the raw test statistics and perform the NPC with the possibility to add sets of weights for weighting variables differently, and/or to select subsets of variables to which NPC has to be applied separately. Note that weights and subsets are placed in the “...” argument of the SOUP function call hence they are not documented in the SOUP help.

Value

an object of class PermSpace or a list containing PermSpace objects, in the case of multiple weights and/or subsets.

Note

This function is mainly taken from the function npc in the package flip.

Author(s)

Federico Mattiello <federico.mattiello@gmail.com>

References

Pesarin, F. and Salmaso, L. (2010) Permutation Tests for Complex Data. Wiley: United Kingdom

Pesarin F. (2001) Multivariate Permutation Tests with Applications in Biostatistics. Wiley: New York.

See Also

t2p


SOUP documentation built on May 2, 2019, 8:18 a.m.

Related to NPC in SOUP...