Raw data

DICOM, NIfTI & ANALYZE file formats. The most common raw form of data collected from the scanner is in DICOM file format. DICOMs from Philips scanners come in two formats, classic and enhanced. The format one wishes to use must be designated when files are transferred from the scanner to hard drive.

DICOMS are most often converted to Neuroimaging Informatics Technology Initiative (NIfTI) format prior to analysis. Most pre-processing and analysis programs use this format and it is also the format supported by the Brain Imaging Data Structure (BIDS). NIfTI files come in two forms, as two separate .img and .hdr files (.img.gz and .hdr.gz in their compressed form) or as a single file, .nii (or .nii.gz in its compressed form).

There may be notable differences in the conversion of enhanced DICOM to NIfTI format. Issues may arise when converting the raw data to files that conform to BIDS (see https://github.com/rordenlab/dcm2niix/issues/170).

Image may contain: .

 

It is advisable to maintain the original raw data even after NIfTI conversion. Some data repositories may prefer DICOMs over NIfTI format. Full re-conversion from NIfTI to DICOM format is not possible due to the complex nature of DICOMs and the metadata lost when converting to NIfTI format. BIDS makes up for the loss of this metadata with the creation of JSON sidecar files at the point of conversion.

It is also possible to download raw data in the NIfTI format directly from the scanner, however, most projects opt to transfer the complete DICOM files and convert them after. This is in part because DICOM files contain rich metadata embedded in the headers which are not present in the headers associated with other file types. DICOMs are stored in folders which contain images for each individual slice, while NIfTI compiles these images into one cohesive file (except when using a BIDScompatible convertor, in which case a JSON file is also created). The headers for DICOMs are embedded within in the file and can be read in neuroimaging software and MATLAB by calling the dicom_info function. The NIfTI compiled file format also has an embedded header, albeit lacking much of the details found in DICOM metadata. As previously stated, JSON sidecar files may be created to preserve this metadata. The two-file NIfTI format comes in .img files with the actual image data and .hdr files with the header information, but has similar metadata limitations to the .nii file. For more information on how to understand NIfTI headers, see: https://brainder.org/2012/09/23/the-nifti-file-format/.

Prior to conversion to NIfTI, DICOMS may need to be renamed and sorted. It is important to keep in mind that they may have the same name as other DICOM files when taken directly from the scanner. This can lead to some files being mistakenly overwritten if transferred to the same folders. Occasionally, researchers have also experienced that the individual DICOM files may be extracted from the scanner in an unexpected order, which will result in the need for resorting to prevent error messages when converting to other file formats. For the sake of the safety of the raw data, new, renamed files should always be directed at a different folder, while maintaining the original DICOMS in the previous folder. We recommend automating this process. MATLAB and Pydicom (python-based) are good options for this.

Those using other modalities along with MRI will have other raw data forms to maintain. For EEG, these files are generated on the EEG laptop located at the scanner. These files are the result: the header, marker, and a binary data file. The files from the EEG at the scanner are proprietary Brain Vision files. Brain Vision is on of the file formats supported by BIDS for EEG. The other most common file type used in EEG is the proprietary Biosemi file format. For more information on these data types, please see our guide Working with EEG Data.

Image may contain: Text, Font, Line.

Transfer of Raw Data

Data from the MR scanner, EEG and behavioral data are transported from the hospital to the department via portable, password-protected encrypted disks. It is important that transfer of the DICOM images occurs at the time of data capture, as data is not kept long term at the scanner.

Data is transferred to Lagringshotell or TSD using the following steps. First, the responsible party contacts the data manager. The password-protected encrypted disk is then delivered to the data manager (you must also provide the password). The images are then uploaded and made available to you in Lagringshotell. General info on the usage of Lagringshotell can be found here (in Norwegian): https://www.uio.no/tjenester/it/hosting/storage/lagringshotell/.

Behavioral Data

The type of files generated when collecting behavioral data differ depending on which program was used. This guide will briefly discuss the different data types produced by the most commonly used programs: E-Prime, PsychoPy, Presentation and PsychToolbox

E-Prime

E-Prime is a suite of programs which simplify the creation, execution and analysis of psychology experiments. It uses a number of proprietary and standard file types in creation of experiments, result reporting and analysis. File extensions in Eprime will vary depending on the version of E-Prime used to write the file. Newer EPrime files with 2.x and 3.x suffixes cannot be used in legacy E-Prime versions (1.x). E-Prime will ask if you wish to convert the files when used with a newer version.

Image may contain: Text, Font, Line.

Psych Toolbox

Psych Toolbox, another popular experiment and stimuli presentation program, is built as an open access add-on to MATLAB and GNU Octave. As such, the files that you will encounter, as well as the syntax, are all the same as those encountered in MATLAB. These files' content in the context of Psych Toolbox are detailed below:

Image may contain: Text, Font, Line.

Presentation

Presentation is popular proprietary software option for the creation of neuroscience experiments. It has three primary file types that you will encounter. The program uses two proprietary, easy to learn languages, Presentation Control Language (PCL) and Scenario Description Language (SDL). SDL is a language used to create experiment design elements like variables or duration times. PCL is the actual programming language used for writing the actual scripts.

SDL elements are read and held in the memory prior to the execution of the code written in PCL.

Image may contain: Text, Font, Line.

Data outputs from presentation come in the form of log files and output text files:

Image may contain: Text, Font, Line.

PsychoPy

PsychoPy is a free and open source presentation software which is functional across operating systems. Researchers can create their experiments using its Builder interface or by writing code in Python. PsychoPy additionally makes it possible to conduct experiments online. One benefit of using PsychoPy is that it is free and doesn’t require a license for costly programs like MATLAB or E-Prime. Additionally. PsychoPy is also a great alternative for those who wish to adhere to the open science initiative because it is accessible for all when sharing experiments along with datasets. It uses basic xml files which can be read in other programs in addition to PsychoPy. The experiment files generated by the program or researcher are:

Image may contain: Text, Font, Line.

PsychoPy creates a folder after a run called “data” as well as a .py file. Inside of the folder you will find the data for analysis. The files you will see are as follows:

Image may contain: Text, Font, Line.

 

PREV

NEXT

By Elian E. Jentoft, Andreas Voldstad & Rene Skukies
Published Aug. 31, 2020 6:37 PM - Last modified Aug. 31, 2020 11:16 PM