EV: EV

View source: R/event_vector.R

EVR Documentation

EV

Description

Factory function for creating event objects (e.g. event_factor, event_variable, event_basis, event_matrix) based on the type of input values.

Usage

EV(
  vals,
  name,
  onsets,
  blockids,
  durations = 1,
  subset = rep(TRUE, length(onsets))
)

Arguments

vals

Event values.

name

Name of the event variable.

onsets

Numeric vector of event onsets.

blockids

Numeric vector of block IDs.

durations

Numeric vector of event durations (or scalar).

subset

Logical vector indicating which events to keep.

Value

An event object.

Examples

ev_fac <- EV(factor(c("A", "B", "C")), "fac", onsets = c(1, 10, 20), blockids = rep(1, 3))


bbuchsbaum/fmrireg documentation built on March 1, 2025, 11:20 a.m.