Viewing FEAT analyses¶
FSLeyes has some features which can help you to view and explore the results of your FEAT analyses.
Loading a FEAT analysis¶
You can load a FEAT analysis in a few different ways [*]:
From the command line - you can specify either a
.feat
directory:fsleyes path/to/my_analysis.feat
Or the
filtered_func_data
image:fsleyes path/to/my_analysis.feat/filtered_func_data
Via File ⇒ Add overlay from directory - select your
.feat
analysis directory.Via File ⇒ Add overlay from file - select the
filtered_func_data
image located in your.feat
analysis directory.
In fact, you can load any NIFTI image contained within a .feat
analysis
directory - FSLeyes will automatically detect that the image is part of a FEAT
analysis. However, the filtered_func_data
image must be loaded in order to
view time series and model fits.
[*] | FSLeyes 0.15.2 does not contain any special functionality for
higher-level FEAT analyses (.gfeat directories). But you can load
and view the individual cope*.feat directories contained within a
.gfeat directory. Future versions of FSLeyes will add
functionality for working with group analyses. |
The FEAT perspective¶
The FEAT perspective arranges the FSLeyes interface for viewing FEAT analyses.

The FEAT perspective simply adds a cluster panel, and a time series panel to the default perspective.
You can activate the FEAT perspective via the View ⇒
Perspectives ⇒ FEAT mode menu item. Or you can tell FSLeyes to
start up with the FEAT perspective via the command line
(the -s
flag is short for --scene
):
fsleyes -s feat path/to/my_analysis.feat
Viewing clusters (the cluster panel)¶
If you have used cluster thresholding in your FEAT analysis, the cluster panel allows you to browse the clusters that were found in each contrast of your analysis.

The controls at the top of the cluster panel allow you to:
- Change the contrast that you are viewing cluster results for.
- Load the Z statistic image for the current contrast. The image is displayed as a volume overlay.
- Load a cluster mask image for the current contrast. The image is displayed as a label overlay, highlighting the clusters that were deemed significant for this contrast.
The table in the cluster panel lists all of the clusters that were found to be
significant for the current contrast. The information shown in this table is
similar to that which can be generated with the FSL cluster
tool. The
→ buttons embedded in the table allow you to move the display to
the following locations for a given cluster:
- The location of the maximum Z value in the cluster
- The location of the clutser’s centre of gravity
- The location of the maximum COPE value in the cluster
Viewing model fits in the time series panel¶
The time series view contains
functionality specific to FEAT analyses. When the selected overlay is from a
FEAT analysis (and the filtered_func_data
image from that analysis is
loaded), the time series view will plot the time series for the current voxel,
and will also plot the full GLM model fit for that voxel. You can also plot
several other types of data from a FEAT analysis, including explanatory
variables (EVs), parameter estimates (PEs) and contrasts of parameter
estimates (COPEs).
When an image from a FEAT analysis is selected, the plot control panel adds a group of settings allowing you to control what is plotted. See the GLM refresher below for more details on what the options mean:

- Plot data This setting is selected by default. When selected, the input data for the current voxel is plotted.
- Plot full model fit This setting is selected by default. When selected, the full model fit at the current voxel is plotted.
- Plot residuals When selected, the residuals of the full model fit (the noise) at the current voxel is plotted.
- Plot reduced data against This setting allows you to plot a “reduced” version of the data at the current voxel, against any of the PEs or COPEs in the analysis.
- Plot EV A checkbox is added for each EV in your design, allowing you to plot them alongside the data.
- Plot PE fit A checkbox is added for each PE in the analysis, allowing you to plot the model fit for any of them at the current voxel.
- Plot COPE fit A checkbox is added for each COPE in the analysis, allowing you to plot the model fit for any of them at the current voxel.
GLM refresher¶
The following overview pertains to fitting a model to the time course for a single voxel.
Let’s say that we have an experimental model comprising a single explanatory variable (EV). For a voxel with an observed time course \(\boldsymbol{Y}\), over \(n\) time points:
And an expected time course \(\boldsymbol{X}\) (the time course of our EV):
The aim of the General Linear Model (GLM) is to obtain the best fit of \(\boldsymbol{X}\) to \(\boldsymbol{Y}\), by finding the best values for the parameter estimates (PEs) \(\boldsymbol{\beta}\) in the following equation:
This is equivalent to finding the minimum value for the residual error \(\boldsymbol{\epsilon}\).
With a single EV (i.e. \(\boldsymbol{X}\) is a column vector), we end up with a single PE \(\boldsymbol{\beta}\). With \(p\) EVs (i.e. \(\boldsymbol{X}\) is a \(p\times n\) matrix), \(\boldsymbol{\beta}\) will be a vector of PEs, one for each EV:
A contrast of parameter estimates (COPE) is simply a linear combination of PEs, and is defined with a contrast vector. Let’s say our experimental design comprises three EVs (i.e. \(p = 3\) in the above equations), and we are interested in the first. The contrast vector (or simply the contrast) would be:
The COPE for this contrast is then the elementwise product of the contrast vector \(\boldsymbol{C}\) and the parameter estimates \(\boldsymbol{\beta}\):
Understanding FEAT time series plots¶
With the above refresher, we can now describe what FSLeyes plots, when you view the results of a FEAT analysis. A few of the options are straightforward to interpret:
- Plot data This option plots the voxel time course \(\boldsymbol{Y}\).
- Plot residutals This option plots the residual error \(\boldsymbol{\epsilon}\).
- Plot EV These options plot the EVs, i.e. the columns of \(\boldsymbol{X}\).
Full and partial model fits¶
The Plot full model fit, Plot PE fit and Plot COPE fit options all work in a similar manner, so are described together. Each of these options plot the GLM model fit for a specific contrast vector.
For a contrast \(\boldsymbol{C}\), the model fit \(\boldsymbol{F_C}\) at time \(t\) is calculated as:
where:
- \(p\) is the number of EVs in the design matrix,
- \(X_e^t\) is the value in the design matrix for EV \(e\) at time \(t\),
- \(\beta_e\) is the parameter estimate for EV \(e\), and
- \(|C_e|\) is the absolute value in the contrast vector for EV \(e\). The absolute value is used because the parameter estimate \(\beta_e\) should already have an appropriate sign.
The contrast vector \(\boldsymbol{C}\) is defined as follows:
- For the Plot full model fit option, the contrast \(\boldsymbol{C}\) is simply a vector of ones.
- For the Plot PE fit options, \(\boldsymbol{C}\) is a vector containing a one for the EV corresponding to the PE, and zeros everywhere else.
- For the Plot COPE fit options, the contrast is the contrast vector that was used in the FEAT analysis.
A few further steps are applied to the above process:
The contrast vectors are normalised before the model fit is calculated:
\[\boldsymbol{C} = \frac{\sqrt{n_\boldsymbol{C}}\boldsymbol{C}}{\sqrt{\sum_{e=1}^{p}{C_e^2}}}\]where \(n_\boldsymbol{C}\) is the number of non-zero elements in the contrast vector. This normalisation is applied purely for display purposes, so that partial model fits are scaled in a sensible manner.
If the analysis is a first-level analysis (i.e. fitting a model to time series data), the data mean is added to the model fit. This is because FEAT de-means time series data before calculating the model fit.
Reduced data plots¶
The Plot reduced data against option allows you to plot a “reduced” version of the voxel time course against any of the PEs or COPEs in your analysis. The reduced data \(\boldsymbol{D}\) for a contrast \(\boldsymbol{C}\) is easily calculated:
i.e. the reduced data for a contrast is the sum of the partial model fit for that contrast, and the residual error from the GLM estimation.