antsMotionCorr: Motion Correction

View source: R/antsMotionCorr.R

antsMotionCorrR Documentation

Motion Correction

Description

This program is a user-level registration application meant to utilize ITKv4-only classes. The user can specify any number of stages where a stage consists of – a transform, an image metric, number of iterations, shrink factors, and smoothing sigmas for each level. Specialized for 4D time series data: fixed image is 3D, moving image should be the 4D time series. Fixed image is a reference space or time slice.

Usage

antsMotionCorr(paramList)

Arguments

paramList

antsMotionCorr parameters, as in ANTs. this is a direct call to the low level c++ and as such has non-standard parameters.

Value

0 – Success
1 – Failure

Note

This function may give different results on multiple runs.

Author(s)

Shrinidhi KL

Examples


# boldfn <- getANTsRData( "pcasl" )
# bold <- antsImageRead( boldfn , 4 )
set.seed(123)
bold <- makeImage(c(10, 10, 10, 20), rnorm(10 * 10 * 10 * 20) + 1)
bold <- iMath(bold, "PadImage", 5)
aimg <- new("antsImage", "float", 3)
aimg <- new("antsImage", "float", 3)
mocoImg <- new("antsImage", "float", 4)
mocoParams <- new("antsMatrix", "double")
antsMotionCorr(list(d = 3, a = bold, o = aimg))
aimg2 <- new("antsImage", "float", 3)
antsMotionCorr(list(d = 3, a = bold, o = aimg2))
antsMotionCorr(list(
  d = 3,
  o = list(mocoParams, mocoImg, aimg),
  m = list(name = "MI", aimg, bold, 1, 32, "Regular", 0.1),
  t = "Rigid[0.01]", i = 25,
  u = 1, e = 1, s = 0, f = 1, n = 25
))
motiondf <- as.data.frame(mocoParams)


stnava/ANTsR documentation built on April 16, 2024, 12:17 a.m.