Overloaded operators for nifti objects

# S4 method for nifti,nifti
Ops(e1, e2)

# S4 method for nifti,numeric
Ops(e1, e2)

# S4 method for numeric,nifti
Ops(e1, e2)

Arguments

e1

is an object of class nifti.

e2

is an object of class nifti.

Author

John Muschelli muschellij2@gmail.com

Examples


img01 <- nifti(array(1:64, c(4,4,4,1)), datatype=4)
img02 <- nifti(array(64:1, c(4,4,4,1)), datatype=4)
is.nifti(img01 + img02)
#> [1] TRUE
is.nifti(sqrt(2) * img01)
#> [1] TRUE
is.nifti(img02 / pi)
#> [1] TRUE