CHAPTER 2 DEVELOPMENT OF THE TOOLBOX
2.1 Standard Multivariate Pattern Analysis
2.1.1.1 Determining of Regions of Interest
As discussed earlier in Section 2.1 the toolbox implements four main analyses, which differ primarily in their approach to feature selection. These analyses as previously noted, fall into two groups: those focusing on the behaviour of specific regions of interest, and those
considering the whole brain. It follows that similar divisions are found in the sections of the toolbox responsible for identifying the regions of interest, and selecting the relevent voxels from them.
The initial identification of regions of interest is performed manually outside the toolbox. For voi-based analyses this is typically done through the identification of standard regions of interest, using a combination of anatomical and functional localiser scans such as those described by Sereno et al (1995), while for whole brain analyses this is performed solely by use of the anatomical scans to generate a mask indicating which voxels are grey-matter, and thus of interest to our analysis.
Corresponding to the four main analyses, the toolbox also employs four main methods for the identification of voxels which are relevent to the analyses:
• Raw region of interest which uses no further processing after the initial definition of
the region of interest, but rather relies on subsequent methods to identify the relevent voxels.
• Grey Matter Masking which limits the voxels to only those which are indicated as
• Static Masking and Ordering which selects voxels based on a single set of statistics
per participant
• Dynamic Masking and Ordering which selects voxels based on a separate set of
statistics per cross-validation set.
The first two of these methods are primarily used with recursive feature elimination (RFE) and searchlight feature selection methods respectively, and rely on these to make further selection of relevent voxels. The latter two methods – static and dynamic masking and ordering – are chiefly used by the voi-size feature selection method. These static and dynamic region of interest selection methods are similar, sharing a common processing structure as shown in Figure 2.4.
voxels = load the set of voxels from the pre-defined region of interest. mask_statistics = load the voxel statistics from the pre-calculated map. voxels = voxels(mask_statistic > masking threshold)
order_statistics = load the voxel statistics from the pre-calculated map. voxels = sort voxels in descending order by order_statistic
voxels = crop to first desired_num_voxels voxels voxel_set = create StaticVoi(voxels)
Listing 2.1: Pseudo code for applying static masking and ordering to a region of interest.
voxels = load the set of voxels from the pre-defined region of interest. statistics = load the voxel statistics from the pre-calculated map. voxels = voxels(statistic > masking threshold)
for each test run
dynamic_statistics = load voxel statistics for this test run run_voxels{run_index} = sort voxels in descending order by
dynamic_statistics
run_voxels = crop to first desired_num_voxels run_voxels end for
voxel_set = create DynamicVoi(run_voxels)
Listing 2.2: Pseudo code for applying dynamic masking and ordering to a region of interest.
As shown in Figure 2.4 and Listings 2.1 & 2.2, the process consists of two key steps: first applying thresholding to the values in a pre-calculated statistical map to identify voxels which show a significant involvement in processing of the presented stimuli, then cropping the remaining voxels to a specified number of the voxels showing the highest involvement, as determined by sorting using a second satistical map, which may potentially be the same as the first.
The static and dynamic methods share the first masking stage in common; and while both also apply the sorting and cropping stage, the key difference between the two lies in the nature of the statistics which can be employed here.
The requirements of the static method are the same as those of the first step; since both use a single set of statistics for all cross-validation sets it is required that the statistics used are not directly related to the main contrast used in the analysis. A common approach, and one recommended for use with the toolbox, is to use the degree to which voxels respond to the set of all stimuli; by contrasting this activation with baseline levels using a t-test, a measure of the significance of the response of each voxel can be generated. Since this contrast does not pre- select voxels which show a difference in response between the various stimulus classes it is safe to include the entire dataset in the calculation.
The dynamic method allows for the use of statistics which are directly related to the main contrast, such as an ANOVA test of the activation evoked by each stimulus category, by using a separate set of statistics for each cross-validation. By using multiple statistical maps we can ensure that each is generated using only samples belonging to the training set of that cross- validation fold, and so avoid breaking the independence of training and testing data.
These processes for region of interest selection are implemented as a set of three classes as shown in Figure 2.3. The raw region and searchlight methods are each handled by their own class, while the static and dynamic masking and ordering processes are both implemented by
the VoiList class, due to their common process. These modules are implemented separately from the feature selection methods which use them to allow for re-use in other scripts, such as the univariate analyses discussed in Section 2.2 which do not require further feature selection.
The resulting voxel sets produced by these region of interest selection processes are
encapsulated in classes which extend the abstract class Voi. For processes which result in the same set of voxels for all cross-validation sets, such as static masking and ordering, this is the StaticVoi class, while for the dynamic masking and ordering process this is the
DynamicVoi class. By encapsulating these voxel sets, the rest of the toolbox can retrieve the required set of voxels for the current cross-validation set using a common interface and without needing to know how they were selected.