open-discussion
open-discussion > RE: Add variables to NiFTi file
Jun 1, 2011 03:06 PM | Ged Ridgway
RE: Add variables to NiFTi file
Hi Namheon,
I think the answer depends on exactly what you mean by adding variables. If you mean adding a dimension for time, in addition to x, y and z, then NIfTI supports that already, without you having to put extensions in. Similarly, if you mean that you want each voxel (over three or four dimensional space) to store a vector, then that is supported already too -- you just put the vector elements along the 5th dimension of the NIfTI, and set the intent code appropriately, see:
http://nifti.nimh.nih.gov/nifti-1/docume...
If you want each voxel to have an intensity, and then a separate 4d vector as well, then you could either simply store a 5d vector, with the intensity as e.g. the first element, and then separate this from the vector in your code, or you could store separate .nii files for the intensity and the vector information (probably better, since any programs intended to visualise images and/or vectors might have a chance of working).
I hope that helps!
Ged
P.S. I think further questions on NIfTI would probably be better on the NIfTI message board:
http://nifti.nimh.nih.gov/board
rather than in the open-discussion forum here.
I think the answer depends on exactly what you mean by adding variables. If you mean adding a dimension for time, in addition to x, y and z, then NIfTI supports that already, without you having to put extensions in. Similarly, if you mean that you want each voxel (over three or four dimensional space) to store a vector, then that is supported already too -- you just put the vector elements along the 5th dimension of the NIfTI, and set the intent code appropriately, see:
http://nifti.nimh.nih.gov/nifti-1/docume...
If you want each voxel to have an intensity, and then a separate 4d vector as well, then you could either simply store a 5d vector, with the intensity as e.g. the first element, and then separate this from the vector in your code, or you could store separate .nii files for the intensity and the vector information (probably better, since any programs intended to visualise images and/or vectors might have a chance of working).
I hope that helps!
Ged
P.S. I think further questions on NIfTI would probably be better on the NIfTI message board:
http://nifti.nimh.nih.gov/board
rather than in the open-discussion forum here.
Threaded View
| Title | Author | Date |
|---|---|---|
| Namheon Lee | May 31, 2011 | |
| Ged Ridgway | Jun 1, 2011 | |
| Tamás Spisák | Jun 1, 2011 | |
