# trimbt.ccmc: One sample percentile bootstrap test with cluster correction... In kevinprinsloo/CCMC: Cluster Based Correction For Multiple Comparisons

## Description

One sample percentile bootstrap test with cluster correction for multiple comparisons

## Usage

 ```1 2``` ```trimbt.ccmc(x, nullval = 0, tr = 0.2, alpha = 0.05, bt = TRUE, nboot = 599) ```

## Arguments

 `x` A list or a matrix. In the first case x contains the data for the first group, x the data for the second group, etc. Length(x) = the number of groups = J. If stored in a matrix, columns correspond to groups. `nullval` The null value against which to compare the trimmed mean - default = 0. `tr` The amount of trimming - default 0.2. Set tr=0 for a t-test on means. `alpha` Alpha level - default 0.05. `bt` Set to TRUE to compute critical t values, p values and confidence intervals based on boostrap-t distributions, otherwise use standard calculations - default = TRUE `nboot` Number of bootstrap samples - default = 599

## Details

One sample t-test on trimmed means with cluster correction for multiple comparisons

## Value

A list of univariate t values, p values and confidence intervals, as well as cluster-based statistics.

estimate = mean or trimmed mean

ci = confidence interval

tval = t values

pval = p values

cluster.th = cluster threshold

cluster.map = vector of cluster IDs

cluster.sig = statistical significance based on cluster test

NA

## Examples

 ``` 1 2 3 4 5 6 7 8 9 10 11 12 13 14``` ```# no effect: set.seed(21) x <- matrix(rnorm(100), ncol = 5) trimbt.ccmc(x,nullval=0,tr=0,alpha=.05,bt=FALSE,nboot=599) # cluster of length 3: set.seed(21) x <- matrix(rnorm(100), ncol = 5) x[,3:5] <- x[,3:5] + 1 trimbt.ccmc(x,nullval=0,tr=0,alpha=.05,bt=FALSE,nboot=599) # use bootstrap-t thresholds trimbt.ccmc(x,nullval=0,tr=0,alpha=.05,bt=TRUE,nboot=599) # get cluster statistics for cluster 1: out <- trimbt.ccmc(x,nullval=0,tr=0,alpha=.05,bt=TRUE,nboot=599) c2sum <- sum(out\$tval[out\$cluster.map==1]^2) ```

kevinprinsloo/CCMC documentation built on May 14, 2020, 12:35 a.m.