writeMRI | R Documentation |
Write an MR image into a file of different formats.
writeMRI(data, file, header, format)
data |
MRI data in a three dimensional array or four
dimensional array with the forth dimension equal to 1.
It could be also an object of class "nifti" or "anlz" as
defined in the package
|
file |
the name of the image file to be written out. |
header |
the header file. |
format |
the format of the image file. Right now only the "Analyze", "NIfTI", and raw byte (unsigned with 1 byte per element in the byte stream) gzip formats are supported. |
Header file is not needed for the file of "Analyze" or "NIfTI" format anymore.
Files of "Analyze" format are written out through
the function writeANALYZE
.
Files of "NIfTI" format are written out through
the function writeNIfTI
.
Nothing is returned.
writeANALYZE
,
writeNIfTI
## Not run: writeMRI(vol, file="vol.rawb.gz", header=NULL, format="rawb.gz") writeMRI(vol, file="vol", header=NULL, format="nifti") writeMRI(vol, file="vol", header=NULL, format="analyze") ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.