read.nifti | R Documentation |
Read data (header/image) from nifti/analyze file
read.nifti(fname)
fname |
nifti/analyze filename |
If you have a both a .hdr and .img, you can input the filename of either
nifti
object
Some of the C code that this function calls was borrowed from Rniftilib
Zarrar Shehzad
read.nifti.header
, write.nifti
object
fname <- file.path(system.file("data", package="niftir"), "test.nii.gz") # 2x2x2 size file # or fname <- file.choose() nim <- read.nifti(fname) nim[1,1,2] # returns voxel value at x=1, y=1, z=2 header(nim) # returns header attributes as a list
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.