spm12_slice_timing: SPM12 Slice Timing Correction

Description Usage Arguments Value

View source: R/zzz_spm12_slice_timing.R

Description

Performs SPM12 slice timing correction on images

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
spm12_slice_timing(
  filename,
  time_points = NULL,
  nslices,
  tr,
  ta = tr - tr/nslices,
  slice_order = 1:nslices,
  ref_slice,
  prefix = "a",
  add_spm_dir = TRUE,
  spmdir = spm_dir(verbose = verbose, install_dir = install_dir),
  clean = TRUE,
  verbose = TRUE,
  outdir = tempdir(),
  retimg = FALSE,
  reorient = FALSE,
  install_dir = NULL,
  ...
)

build_spm12_slice_timing(
  filename,
  time_points = NULL,
  nslices,
  tr,
  ta = tr - tr/nslices,
  slice_order = 1:nslices,
  ref_slice,
  prefix = "a",
  add_spm_dir = TRUE,
  spmdir = spm_dir(verbose = verbose, install_dir = install_dir),
  clean = TRUE,
  verbose = TRUE,
  outdir = tempdir(),
  install_dir = NULL,
  ...
)

Arguments

filename

Files to be slice-time corrected

time_points

A vector of time points to run slice-time correction. If filename is a 4D file, then will do all the time points. Otherwise, filename must be a character vector of 3D files or a list of 3D nifti objects.

nslices

Number of slices in the images

tr

Repetition time (in seconds)

ta

Time between the first and the last slice within one scan

slice_order

Order slices were taken (if not specified, assumed ascending), bottom slice = 1

ref_slice

Reference slice

prefix

Prefix to append to front of image filename

add_spm_dir

Add SPM12 directory from this package

spmdir

SPM dir to add, will use package default directory

clean

Remove scripts from temporary directory after running

verbose

Print diagnostic messages

outdir

Directory to copy results

retimg

(logical) return image of class nifti

reorient

(logical) If retimg, should file be reoriented when read in? Passed to readNIfTI.

install_dir

directory to download SPM12

...

Arguments passed to run_spm12_script

Value

List of results, the SPM job, the script and the outfile


spm12r documentation built on March 4, 2021, 9:11 a.m.