gen_groupPC: Generate Group-Level Principal Components (PCs) for fMRI Data

View source: R/groupICA.R

gen_groupPCR Documentation

Generate Group-Level Principal Components (PCs) for fMRI Data

Description

This function computes subject-level principal components (PCs) from fMRI data and performs a group-level PCA for dimension reduction, designed for cortical surface fMRI data in BIDS format.

Usage

gen_groupPC(
  bids_path,
  subj_list,
  n.comp = 30,
  ncore = 1,
  npc = 85,
  iter_std = 5,
  brainstructures = c("left", "right"),
  verbose = TRUE
)

Arguments

bids_path

A character string specifying the root directory of the BIDS-formatted dataset.

subj_list

A named list generated from create_group_list containing fMRI file paths for each subject.

n.comp

An integer specifying the number of components to retain during group-level PCA. Default is 30.

ncore

An integer specifying the number of cores to use for parallel processing. Default is 1.

npc

An integer specifying the number of components to retain during subject-level PCA. Default is 85.

iter_std

An integer specifying the number of iterative standardization steps to apply to fMRI data. Default is 5.

brainstructures

A character vector specifying the brain structures to include in the analysis. Options are "left" (left cortex), "right" (right cortex), and/or "subcortical" (subcortex and cerebellum). Can also be "all" (obtain all three brain structures). Default is c("left", "right").

verbose

A logical value indicating whether to print convergence information during execution. Default is TRUE.

Details

NOTE: This function requires the ciftiTools package to be installed, and set up the path to the Connectome Workbench folder by ciftiTools.setOption(). See the package ciftiTools documentation for more information.

Value

A numeric matrix containing the group-level principal components, with dimensions determined by the number of retained components (n.comp) and the concatenated data across all subjects.


SparseICA documentation built on April 12, 2025, 1:50 a.m.