make_design | R Documentation |
Make the design matrix for the GLM, from the task information.
make_design(
EVs,
nTime,
TR,
dHRF = 0,
upsample = 100,
onset = NULL,
offset = NULL,
scale_design = TRUE,
onsets_sep = FALSE,
offsets_sep = FALSE,
verbose = TRUE,
...
)
EVs |
The explanatory variables i.e. the task stimulus information,
from which a design matrix will be constructed. This is a list where each
entry represents a task as a matrix of onsets (first column) and durations
(second column) for each stimuli (each row) of the task, in seconds. List
names should be the task names. An example of a properly-formatted |
nTime |
the number of timepoints (volumes) in the task fMRI data. |
TR |
the temporal resolution of the data, in seconds. |
dHRF |
Controls the extent of HRF derivatives modeling. Set to If there are several tasks and |
upsample |
Upsample factor for convolving stimulus boxcar or stick
function with canonical HRF. Default: |
onset , offset |
Add task regressors indicating the onset and/or offset of
each event block? Provide the names of the tasks as a character vector. All
onsets (or offsets) across the specified tasks will be represented by one
additional column in the design matrix. The task names must match the names
of Onsets/offset modeling is only compatible with a block design experiment.
An error will be raised if the events in |
scale_design |
Scale the columns of the design matrix? Default:
|
onsets_sep , offsets_sep |
Model the onsets ( |
verbose |
Print diagnostic messages? Default: |
... |
Additional arguments to |
A "BfMRI_design"
object: a list with elements
The volumes by fields design matrix. Column names are field names.
The name of each task from the provided onsets.
The input dHRF
parameter.
Additional HRF modeling results.
EVs <- list(taskA=cbind(on=c(1,9,17), dr=rep(1,3)), taskB=cbind(on=c(3,27), dr=rep(5,2)))
TR <- .72
nTime <- ceiling(65/TR)
make_design(EVs, nTime, TR)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.