evaluate.HRF: evaluate.HRF

View source: R/hrf.R

evaluate.HRFR Documentation

evaluate.HRF

Description

This function evaluates a hemodynamic response function (HRF) for a given set of time points (grid) and other parameters. It is used to generate the predicted BOLD (blood-oxygen-level-dependent) signal changes in fMRI data analysis.

Usage

## S3 method for class 'HRF'
evaluate(
  x,
  grid,
  amplitude = 1,
  duration = 0,
  precision = 0.2,
  summate = TRUE,
  normalize = FALSE,
  ...
)

Arguments

x

The HRF function.

grid

A vector of time points.

amplitude

The scaling value for the event (default: 1).

duration

The duration of the event (default: 0).

precision

The temporal resolution used for computing summed responses when duration > 0 (default: 0.2).

summate

Whether the HRF response increases its amplitude as a function of stimulus duration (default: TRUE).

normalize

Scale output so that peak is 1 (default: FALSE).

Value

A vector of HRF values at the specified time points.

Examples

hrf1 <- evaluate(HRF_SPMG1, grid=seq(0,20,by=1.5), duration=2, precision=.1)
hrf2 <- evaluate(HRF_SPMG1, grid=seq(0,20,by=1.5), duration=2, precision=.1, summate=FALSE)

bbuchsbaum/fmrireg documentation built on May 16, 2023, 10:56 a.m.