antsCopyImageInfo: Copy header info

View source: R/antsCopyImageInfo.R

antsCopyImageInfoR Documentation

Copy header info

Description

Copy origin, direction, and spacing from one antsImage to another

Usage

antsCopyImageInfo(reference, target)

Arguments

reference

image object of S4 class antsImage to get values from.

target

image object of S4 class antsImage to copy values to.

Value

Target image with reference header information.

Examples


img <- makeImage(c(10, 10), rnorm(100))
img2 <- makeImage(c(10, 10), rnorm(100))
img2 <- antsCopyImageInfo(img, img2)
testthat::expect_error(antsCopyImageInfo(img, 1))


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