R/check_ants.R

#' @title Check if antsImage or read in
#' @description Simple check to see if input is character, list, \code{nifti},
#' or class \code{antsImage}
#' @return antsImage object
#' @param x character path of image or 
#' an object of class antsImage
#' @param ... arguments passed to \code{\link{oro2ants}}
#' @rdname check_ants-methods
#' @aliases check_ants,nifti-method
#' @importFrom ANTsRCore check_ants
#' @export
setMethod("check_ants", "nifti", function(x, ...) { 
  x = oro2ants(x, ...)
  return(x)
})
neuroconductor/extrantsr documentation built on Jan. 3, 2020, 10:22 p.m.