Quick start

  1. Create a separate directory to hold the contents of the GLM analysis. This isn't a requirement, but you will find that GLM analyses can create a lot of files. Also, you may want to have several separate GLM analyses, with each grouped in its own directory.

  1. This GLM analysis requires one top level "control file" that specifies various options and also lists the runs (data files) to be analyzed by GLM. The control file format is here. At the top of the file, there are keyword-delimited parameters followed by arguments (e.g., "baseline-terms 3"). The keywork "runs" or "runs:" indicates the end of this section and the beginning of a list of runs. Subsequent lines are:

                          [fMRI data file name]   [GLM description file name]   [optional table file name]

  1. Each run (or "scan" or "data file") requires a "GLM description file" (typical extension is .glm) that specifies the events that occurred during the run and the timing of those events. Additionally, an optional "table file" can be associated with the run and the .glm file in order to employ non-parametric regressors. The table file, if it exists, consists of a set of columns with a single text header on the first line for each column and then one entry per time point for each column. Any "table" events in the GLM description file will point to one of the columns.

  1. Run the GLM, generally using a single argument to convert absolute signal changes to % changes:

glm glm.dat -p

     where "glm.dat" is the name of the control file in this case.

  1. Display the time series and all maps using jip-display (a.k.a, xd):

"xd -t glm.dat &"  or  "xd &"   as shown here

  1. When "glm" was executed in step 4, it created a hidden file named ".display" with default contents:        "xd -t glm.dat". If no arguments are given to "xd", and if this file exists on the current directory, then the arguments within the file will be used. This is why one can type simply "xd" in step 5. Consider modifying file ".display" using an editor to include whatever arguments are useful. Then, when you revisit this directory many months later, you can simply type "xd" to bring up the analysis. Example:

xd -t glm.dat -S -e /space/1/me/template/anatomy.nii -o /space/1/me/template/overlay-list.dat

Joseph B. Mandeville, Athinoula A. Martinos Center for Biomedical Imaging at MGH/MIT/Harvard