Preparing your data for iBEAT

If you want to use iBEAT in the user-friendly way it was designed, it is best to use their directory structure to organize your data. Within your data folder, you will have a folder for each subject. These folders will be named with the subject ID (e.g., S0001). Within each subject folder, you should create a folder for each timepoint. Label the folders with the subject ID and the age of the subject (in months), separated by a dash (e.g., S001-0 for newborn, S001-6 for 6-months old, etc). Within each timepoint folder for each subject, you will store the scans. Ideally, you will have a T1-weighted scan, a T2-weighted scan, and an DTI scan with fractional anisotropy (FA). These files will be labeled with the subject ID, age, and type of scan, separated by a dash (e.g., S001-0 folder will have: S001-0-T1, S001-0-T2, S001-0-FA; S001-6 folder will have: S001-6-T1, S001-6-T2, S001-6-FA).

Because this data is being collected from infants undergoing an MRI, it is likely that you will not have all 3 images for every subject. Of course the more data the better, but iBEAT should work with children under 6 months old who have only a T2 scan and children over 6 months old who have only a T1 scan. Around 6 months, the software makes use of both the T1 and T2 to segment the tissue into gray matter and white matter.

iBEAT uses analyze files (.img/.hdr). This is an older filetype; many current softwares such as FSL and SPM use NIFTI (.nii) files.

There are a few ways to convert your files to analyze format. My preference is to use mri_convert through FreeSurfer. If you have Freesurfer installed, use the command mri_convert. For example, to convert a T1.nii image to a T1.img/T1.hdr pair of images, I used the following command:

mri_convert –in_type nii –out_type analyze T1.nii T1.img

Once you have converted the scans to the correct format, be sure to move any other files that share the same name with a different filetype/extension. For example, if you used the mri_convert code to extract T1.nii inside the subject’s timepoint folder, you will now have files called “T1.nii, T1.mat, T1.img, and T1.hdr.” Remove the T1.nii and T1.mat files from this folder. Having files aside from the .img/.hdr files inside of the same folder can cause errors with iBEAT’s calculations of the reorientation parameters (Step 1: Image Preprocessing).

You may also have additional data for each subject (e.g., demographics, behavioral measures, functional MRI scans). To avoid iBEAT errors as much as possible, store this additional data separately.

Check that your subject directories look something like this:

S001:

S001-0:

S001-0-FA.hdr

S001-0-FA.img

S001-0-T1.hdr

S001-0-T1.img

S001-0-T2.hdr

S001-0-T2.img

S001-6:

S001-6-FA.hdr

S001-6-FA.img

S001-6-T1.hdr

S001-6-T1.img

S001-6-T2.hdr

S001-6-T2.img

S002:

S002-0:

S002-0-FA.hdr

S002-0-FA.img

S002-0-T1.hdr

S002-0-T1.img

S002-0-T2.hdr

S002-0-T2.img

S002-6:

S002-6-FA.hdr

S002-6-FA.img

S002-6-T1.hdr

S002-6-T1.img

S002-6-T2.hdr

S002-6-T2.img

If it does, you are now ready to start processing your data with iBEAT!

Leave a comment