R/mgh.dims.R

Defines functions mgh.dims

Documented in mgh.dims

mgh.dims <- function(mgh.file) {
  
  stopifnot(file.exists(mgh.file))
  
  hdr <- mgh.hdr(mgh.file, c("width", "height", "depth", "nframes"))
  
  dims <- c(hdr$width, hdr$height, hdr$depth, hdr$nframes)
  # if (dims[4] == 0) {
  #   dims <- dims[-4]
  # }
  return(dims)
}
TKoscik/fsurfR documentation built on Aug. 5, 2019, 4:53 p.m.