Compute the cluster mass test with adjacency defined by a graph.

compute_clustermass_array(
  distribution,
  threshold,
  aggr_FUN,
  graph,
  alternative
)

Arguments

distribution

An 3d array representing the null distribution of multiple signal. The first dimension is the permutations, the second the samples, the third is the channels.

threshold

The threshold used to compute the clusters.

aggr_FUN

The function that aggregates the cluster into a scalar value (cluster mass).

graph

A igraph object representing the adjacency of the channels.

alternative

a character string indicating the alternative hypothesis. Either "greater", "less" or "two.sided".

Value

A list containing an igraph object, a data frame containing the channels, time, statistic, cluster-mass and p-values.

References

Maris, E., & Oostenveld, R. (2007). Nonparametric statistical testing of EEG-and MEG-data. Journal of neuroscience methods, 164(1), 177-190, https://doi.org/10.1016/j.jneumeth.2007.03.024.

See also