BayesGLM2 {BayesfMRI} | R Documentation |
Group-level Bayesian GLM
Description
Performs group-level Bayesian GLM estimation and inference using the joint approach described in Mejia et al. (2020).
Usage
BayesGLM2(
results,
contrasts = NULL,
quantiles = NULL,
excursion_type = NULL,
contrast_names = NULL,
gamma = 0,
alpha = 0.05,
nsamp_theta = 50,
nsamp_beta = 100,
num_cores = NULL,
verbose = 1
)
BayesGLM_group(
results,
contrasts = NULL,
quantiles = NULL,
excursion_type = NULL,
gamma = 0,
alpha = 0.05,
nsamp_theta = 50,
nsamp_beta = 100,
num_cores = NULL,
verbose = 1
)
Arguments
results |
Either (1) a length |
contrasts |
(Optional) A list of contrast vectors that specify the
group-level summaries of interest. If Each contrast vector is length
and so the full contrast vector representing the group average across sessions and subjects for the first task would be:
To obtain the group average for the first task, for just the first sessions from each subject:
To obtain the mean difference between the first and second sessions, for the first task:
To obtain the mean across sessions of the first task, just for the first subject:
|
quantiles |
(Optional) Vector of posterior quantiles to return in addition to the posterior mean. |
excursion_type |
(For inference only) The type of excursion function for
the contrast (">", "<", "!="), or a vector thereof (each element
corresponding to one contrast). If |
contrast_names |
(Optional) Names of contrasts. |
gamma |
(For inference only) Activation threshold for the excursion set,
or a vector thereof (each element corresponding to one contrast). Default:
|
alpha |
(For inference only) Significance level for activation for the
excursion set, or a vector thereof (each element corresponding to one
contrast). Default: |
nsamp_theta |
Number of theta values to sample from posterior. Default:
|
nsamp_beta |
Number of beta vectors to sample conditional on each theta
value sampled. Default: |
num_cores |
The number of cores to use for sampling betas in parallel. If
|
verbose |
Should updates be printed? Use |
Value
A list containing the estimates, PPMs and areas of activation for each contrast.
INLA Requirement
This function requires the INLA
package, which is not a CRAN package.
See https://www.r-inla.org/download-install for easy installation instructions.