parameterImage: Creates parameter image in random locations for simulations

Description Usage Arguments Value

View source: R/master.R

Description

Uses the mask variable to create length(rs) spheres of size rs with values equal to betas within the mask. A random voxel is chosen within the mask and a sphere is placed at that location. The spheres are masked by the mask image so that no parameter values exist outside the mask.

Usage

1
parameterImage(mask, parameterImage, rs, betas)

Arguments

mask

String or niftiImage object indication the area to select sphere locations from.

parameterImage

output nifti for the parameter image.

rs

vector of radii for signal spheres.

betas

vector of parameters for signal spheres. Signal is constant throughout the sphere. Model parameter values are set to params = betas * sd(y)/sd(x).

Value

Returns the parameter image after writing it to file.path(outdir, 'signal.nii.gz').


simonvandekar/NIsim documentation built on Oct. 12, 2020, 5:06 p.m.