Learn R Programming

brainGraph (version 0.48.0)

permute.vertex: Permutation test for group difference of graph vertex measures

Description

This function performs a permutation test looking at the max t-statistic for a given vertex-level graph attribute (e.g. degree). This is the same principle as that of Nichols & Holmes (2001) used in voxelwise MRI analysis.

Usage

permute.vertex(g1, g2, measure, test = c("t.test", "wilcox.test", "lm"),
  alpha = 0.05, N = 1000, ...)

Arguments

g1
A list of igraph graph objects for group 1
g2
A list of igraph graph objects for group 2
measure
A character string of the measure to test
test
Character string for the test to use (passed to group.graph.diffs); one of 't.test', 'wilcox.test', or 'lm'
alpha
The significance level (default: 0.05)
N
The number of permutations (default: 1e3)
...
Other arguments passed to group.graph.diffs

Value

  • A list with the following elements:
  • gA graph representing group differences, with p.perm included as a vertex-level attribute (it is actually 1 - p.perm)
  • p.maxThe proportion of the number of times the maximum t-statistic of the permuted groups was greater than the observed maximum t-statistic
  • threshThe $1 - \alpha$ %ile maximum t-statistic of all permuted values

Details

By default, a t-test is used when calling group.graph.diffs; if you would like to do e.g. a linear model, then see that function's help section and pass the appropriate arguments.

References

Nichols TE & Holmes AP (2001). Nonparametric permutation tests for functional neuroimaging: A primer with examples. Human Brain Mapping, 15(1):1-25.

See Also

sample, group.graph.diffs

Examples

Run this code
g.diff <- permute.vertex(g.wt[[1]][[3]], g.wt[[2]][[3]], measure='degree')
g.diff <- permute.vertex(g[[1]][[5]], g[[2]][[5]], measure='degree',
    test='lm', covars=covars.dti)

Run the code above in your browser using DataLab