indexing: Access to metadata elements

$.niftiImageR Documentation

Access to metadata elements

Description

These methods provide shorthand access to metadata elements from the NIfTI header corresponding to an image. The extraction version returns the corresponding element from the result of niftiHeader, while the replacement version calls asNifti to replace it.

Usage

## S3 method for class 'niftiImage'
x$name

## S3 replacement method for class 'niftiImage'
x$name <- value

Arguments

x

A "niftiImage" object, internal or otherwise.

name

A string naming the field required.

value

A new value for the field.

Author(s)

Jon Clayden <code@clayden.org>

See Also

niftiHeader, asNifti

Examples

im <- readNifti(system.file("extdata", "example.nii.gz", package="RNifti"))
print(im$descrip)


RNifti documentation built on June 22, 2024, 10:20 a.m.