MHPCA_decomp: Multilevel Hybrid Principal Component Analysis

Description Usage Arguments Value

View source: R/m-hpca.R

Description

Function for performing MHPCA decomposition described in "Multilevel Hybrid Principal Components Analysis For Region-Referenced Functional EEG Data" by Campos et al. (202?), including estimation of fixed effects and marginal covariance functions, marginal eigencompoents, subject-specific scores, variance components, and measurement error variance.

Usage

1
2
3
4
5
6
7
8
9
MHPCA_decomp(
  data,
  fve_cutoff,
  nknots,
  maxiter = 1000,
  epsilon = 0.001,
  reduce = TRUE,
  quiet = FALSE
)

Arguments

data

dataframe in long format with six labeled columns (Repetition: (character vector), Subject: subject IDs (character vector), Group: subject group (character vector), func: functional argument (numeric vector), reg: regional argument (character vector), y: region-referenced functional data (numeric vector)) and row length equal to the length of the vectorized region-referenced Repetitions across all subjects and groups

fve_cutoff

fraction of variance cutoff for reducing the number of product components used in the mixed effects model (scalar in (0, 1))

nknots

number of knots to use for smoothing splines

maxiter

maximum number of iterations for MM algorithm (scalar)

epsilon

epsilon value for determining log-likelihood convergence (scalar)

reduce

should the number of product components be reduced and the mixed effects model re-estimated (logical)

quiet

display messages for timing (logical)

Value

A list with


dsenturk/mhpca documentation built on Dec. 20, 2021, 2:11 a.m.