pad_vol: Pad a 3D Array

View source: R/utils_volume.R

pad_volR Documentation

Pad a 3D Array

Description

Pad a 3D array by a certain amount in each direction, along each dimension. This effectively undoes a crop.

Usage

pad_vol(x, padding, fill = NA)

uncrop_vol(x, padding, fill = NA)

Arguments

x

A 3D array, e.g. unmask_subcortex(xifti$data$subcort, xifti$meta$subcort$mask).

padding

A d \times 2 matrix indicating the number of slices to add at the beginning and end of each of the d dimensions, e.g. xifti$meta$subcort$mask_padding.

fill

Values to pad with. Default: NA.

Value

The padded array


mandymejia/ciftiTools documentation built on Feb. 28, 2024, 11:20 a.m.