evaluate.hrfspec: evaluate.hrfspec

View source: R/hrf.R

evaluate.hrfspecR Documentation

evaluate.hrfspec

Description

This function evaluates a hemodynamic response function (HRF) specified by an hrfspec object for a given set of time points (grid) and other parameters. It is a wrapper function that calls the evaluate.HRF function with the HRF function contained in the hrfspec object.

Usage

## S3 method for class 'hrfspec'
evaluate(x, grid, amplitude = 1, duration = 0, precision = 0.1, ...)

Arguments

x

The hrfspec object containing 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.1).

...

Additional arguments to be passed to the evaluate.HRF function.

Value

A vector of HRF values at the specified time points.

Examples

hrf_spec <- hrfspec(hrf = HRF_SPMG1)
hrf_values <- evaluate(hrfspec, grid=seq(0,20,by=1.5), duration=2, precision=.1)

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