design_map.event_model: Visualize the entire design matrix of an event_model as a...

View source: R/event_model.R

design_map.event_modelR Documentation

Visualize the entire design matrix of an event_model as a heatmap

Description

Produces a single heatmap of all columns in the design matrix for an event_model object, with rows corresponding to scan number and columns corresponding to regressors. A white horizontal line separates each block/run.

Usage

design_map.event_model(
  x,
  rescale_cols = TRUE,
  block_separators = TRUE,
  rotate_x_text = TRUE,
  fill_midpoint = NULL,
  fill_limits = NULL,
  ...
)

Arguments

x

An event_model object.

rescale_cols

Logical; if TRUE, columns are rescaled to (-1,1) before plotting.

block_separators

Logical; if TRUE, draw white horizontal lines between blocks.

rotate_x_text

Logical; if TRUE, rotate x-axis labels by 45 degrees.

fill_midpoint

Numeric or NULL; if not NULL, passed as the midpoint argument to ggplot2::scale_fill_gradient2() to center the color scale. If your design matrix has both positive and negative values, you may want fill_midpoint = 0.

fill_limits

Numeric vector of length 2 or NULL; passed to ⁠limits=⁠ in the fill scale. Useful to clip color range.

...

Other arguments passed on to geom_tile().

Value

A ggplot2 plot object.


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