User Tools

Site Tools


processing_stream_-_project_folder_structure

Project folder structure

Motivation

While you are, naturally, free to use any structure to store the diverse files related to your study (e.g. stimulus material, grant documents, physiological measurements, logfiles and onset parameters, fMRI data, structural and DTI scans, etc.), the workflow usually greatly benefits from a more rigorous adaptation and implementation of a specific folder structure.

There are reasons for this:

  • scripts often expect to locate files based on a pattern–if the folder structure differs between subjects, this is likely to fail
  • in case you wish to collaborate with others, it is a lot easier for them to understand the workflow and locate and access the correct files
  • projects follow a life-cycle; once a report or article has been published, it is common to let the data “rest”–if you then access on “old” project, it doesn't require a lot of guesswork to find your way to whatever you're looking for
  • data pruning (removal of intermediate steps, for instance) almost certainly requires a more or less rigid folder and file naming convention

Requirements

Some discipline on your part (and everybody else involved in the project) as well as a good understanding of what kind of analyses you want to perform and how the results should be organized (e.g. do you plan to run cross-correlations between subjects and need a place to store pairwise comparison maps).

The naming convention

Once you decide to implement a specific folder structure, please take a few moments to think about the following issues:

  • who has access to this folder? (you might want to have a separate location for private data, such as grant applications, which you do not wish other people to see who have shared access to the data storage)
  • how can data be stored so that anonymity is secured? (HIPAA and other protocols require that personnel not involved with a project cannot gain knowledge of who took part in a study, for instance)
  • does data need to be stored hierarchically? (e.g. in case you have several groups of subjects you might want to create specific subfolders, or you might want to put the group assignment as a particle into the subject's folder name)
  • what kind of data will be required to successfully implement your tests (for hypothesis driven analyses, you definitely should store the stimulation onsets into the project's folder, so as to have them readily available, in case you need to adapt them or extract onset-locked time courses; also, it is good practice to keep the files the onsets were derived from, such as logfiles, as you might want to confirm that you synced the onsets correctly to the data)

The following is an exemplary suggestion, and you are of course welcome (and usually required) to change it according to your specific needs:

  • subject folder names contain the ID that was generated at the scanner (given it does not allude to the subject's real name/identity), preceded by an abbreviated project tag (acronym), for sorting purposes this should be of equal length for all subjects (e.g. PROJ5191_G1 for subject ID 5191 of project PROJ, a member of group 1)
  • session names should be alphabetically sortable (e.g. if you suspect that subjects might have more than 9 sessions, use a two-digit coding scheme), and potentially contain the number of images and/or a task specifier (in case sessions differ, e.g. run04_214_hand, which is the 4th session with 214 volumes, task is “hand”)
  • volume filenames should preferably be short and consistent (e.g. vol_00001.img for the first volume in a run); if they contain additional information, the volume number should be the last particle before the extension (e.g. s5191-0004-00001.img)

Exemplary folder structure

This example is not meant to be comprehensive in the sense that you will almost certainly experience the need to add your own branches to the structure (and equally drop those that are not required in your situation)!

/Volumes
 | ---- /OlfacStroop
 |       | -------- /Documents
 |       |           | ------ /Literature
 |       |           |         | ------- /2007_Walter_et_al__Olfaction_Attention.pdf
 |       |                                (...) -> further articles to cite
 |       |           Imaging
 |       |           | ---- /Analyses
 |       |           |       | ----- /GLM
 |       |           |       |        |- /OLSTR_21subjects_OLS_masked_PSC.glm
 |       |           |       |        |   (...) -> additional regression results for comparison
 |       |           |       |
 |       |           |       |        (...) -> additional folders with other methods (e.g. ICA, Mediation)
 |       |           |
 |       |           |       Subjects
 |       |           |       | ----- /OLSTR8122
 |       |           |       |        | ------ /anatomical
 |       |           |       |        |         | ------- /spgr
 |       |           |       |        |         |         | - /spgr.nii
 |       |           |       |        |         |         |    (...) -> additional files (normalization parameters, etc.)
 |       |           |       |        |
 |       |           |       |        |         dti
 |       |           |       |        |         |- /dtivol_001.nii
 |       |           |       |        |         |    (...) -> additional files (different gradient directions)
 |       |           |       |        |
 |       |           |       |        |         functional
 |       |           |       |        |         | ------- /run01_240_focus
 |       |           |       |        |         |          | ------------ /akvol_00001.nii
 |       |           |       |        |         |          |               (...) -> volumes 2 through 240, preprocessing
 |       |           |       |        |         |
 |       |           |       |        |         |          run02_240_distract
 |       |           |       |        |         |          (...) -> additional folders (another task, etc.)
 |       |           |       |        |
 |       |           |       |        |         raw
 |       |           |       |        |         |- /240r_3
 |       |           |       |        |             | --- /IM-0003-00001.dcm
 |       |           |       |        |             |      (...) -> additional DICOM files
 |       |           |       |        |
 |       |           |       |        |             (...) -> additional DICOM folders
 |       |           |       |             
 |       |           |       |         (...) -> next subject
 |       |           |       |         
processing_stream_-_project_folder_structure.txt · Last modified: 2010/05/27 00:14 by jochen