error_not_antsImage: Stop if not an antsImage object

View source: R/error_not_antsImage.R

error_not_antsImageR Documentation

Stop if not an antsImage object

Description

Stop if not an antsImage object

Usage

error_not_antsImage(x, argname = "")

Arguments

x

object to test

argname

Name of argument to say was not an antsImage

Value

Invisible NULL

Examples

img <- antsImageRead(getANTsRData("r16"), 2)
error_not_antsImage(img)
testthat::expect_error(error_not_antsImage(as.array(img)))

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