R/sfeatures.R

Defines functions sfeatures

Documented in sfeatures

#' Moment calculation
#'
#'
#' @param obj A target image of Image object or an array.
#' @param ref A reference image of Image object or an array.
#' @export
#' @examples
#' sfeatures()

sfeatures <- function(obj, ref=0){
  if(length(ref)!=1 & !identical(dim(obj), dim(ref))) stop("Dimension mismatch.")
  width <- dim(obj)[1]
  height <- dim(obj)[2]
  nframes <- dim(obj)[3]
  sfeaturesC(obj, ref, width, height, nframes)
}
tkatsuki/dipr documentation built on April 19, 2021, 7:18 p.m.