Learn R Programming

brainGraph (version 0.48.0)

boot_global: Bootstrapping for global graph measures

Description

This function performs bootstrapping to get group standard error estimates of a global graph measure (e.g. modularity). It will output a list containing a data table with standard errors and 95% confidence intervals at each density for each group, and 2 ggplot objects for plotting. This function is intended for cortical thickness networks (in which there is only one graph per group), but will obviously work in other scenarios.

Usage

boot_global(densities, resids, groups, R = 1000, measure = "mod")

Arguments

densities
A vector of graph densities to loop through
resids
A data.table of the residuals (from get.resid)
groups
A character vector indicating group names
R
The number of bootstrap replicates (default: 1e3)
measure
Character string of the measure to test (default: 'mod')

Value

  • A list with the following elements:
  • gA list of boot objects
  • dtA data table with length # densities * # groups
  • p1A ggplot object with ribbon representing standard error
  • p2A ggplot object with ribbon representing 95% confidence interval

Details

The 95% confidence intervals are calculated using the normal approximation.

See Also

boot, boot.ci, permute.group

Examples

Run this code
boot.res <- boot_global(densities, m$resids, groups, 1e3, 'E.global')

Run the code above in your browser using DataLab