Extract or Replace NIfTI/Analyze Min or Max Values

Description

Methods that act on the ‘cal.min’ and ‘cal.max’ numeric value in the NIfTI or ANALYZE header.

Usage

1
2
3
4
## S4 method for signature 'nifti'
cal.min(object)
## S4 method for signature 'nifti'
cal.max(object)

Arguments

object

is an object of class nifti or anlz.

Methods

object = "anlz"

Extract or replace the ANALYZE "cal_min" or "cal_max" value.

object = "nifti"

Extract or replace the NIfTI "cal_min" or "cal_max" value.

Author(s)

Brandon Whitcher bwhitcher@gmail.com

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
url <- "http://nifti.nimh.nih.gov/nifti-1/data/avg152T1_LR_nifti.nii.gz"
urlfile <- file.path(system.file("nifti", package="oro.nifti"),
                     "mniLR.nii.gz")
download.file(url, urlfile, quiet=TRUE)

## End(Not run)
urlfile <- file.path(system.file("nifti", package="oro.nifti"),
                     "mniLR.nii.gz")
mniLR <- readNIfTI(urlfile)
cal.min(mniLR)
cal.max(mniLR)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.