Typical way to do classification

A typical work flow for doing classification analysis is the following:

  1. Define some ROIs you want to use.
  2. load the time series data for those ROIs ('loadROITSeries').
  3. If desired, load auxilary analysis to be used to rank voxel for feature selection (typically an event-related analysis)
  4. rank voxel order used in classification ('getSortIndex')
  5. loop through cross validation runs, in each loop, first split data into training and test runs ('splitRuns'), then get single trial responses for both the training and test data ('getInstances'), then construct a classifier on the training data ('buildClassifier'), then test classifier performance on the test data ('testClassifier').

Quick notes about functions used in classification

  • dispInstances - makes a graph of instances and shows you pca of first couple components
  • dispClassifier - displays the classification - should run exactly like testClassifer
  • splitRuns - separates a concatenated time series data into training and test partition
  • getInstances - obtain single-trial single voxel response for a list of ROIs
  • buildClassifier - builds various types of classifiers on instances, has several arguments for how to do pre-processing and classification.
  • testClassifier - runs classifier on test instances and returns % correct. Note that this (through a sub-function classifyInstance) makes sure that the testInstances are preprocessed in the same way as the build instances.
testClassifier(testInstances,buildClassifier(instances))

Notes on cinvor2 based on contrast only

  1. classifying low vs. high contrast is easy, near ceiling for all subjects and design. However, this is true only for Fisher LDA, the Mahalanobis performed not very well.
  2. PCA with more components is more useful in bigger ROIs (slope of PCA comp steeper with larger ROIs). However, PCA with less than 5 components never outperform regular settings. The PCA trick is not explored extensively.
  3. Bigger ROI with getInstance(deconv method) didn't improve accuracy but seem to help with getInstance (mean method). The canonical response computed from the former is more noisy with bigger ROI (sometimes it doesn't look like a typical gamma-ish function), presumably because of inclusion of noisy voxels.

Notes on cinvor2 based on orientation only (collapsing across contrasts)

  1. PCA component doesn't matter (from 1 to 5), seems reasonable
  2. z-score seems to give best classification performance, especially when using the mean method to get the instances; when using deconv method, z-scoring doesn't do much.
  3. For block design, getInstance(mean) is better than getInstance(deconv), presumably because deconv is not working very well for short blocks without jitter.
  4. For event-related design, getInstance(mean) is similar to getInstance(deconv). The latter improved presumably because it's easier to estimate single-trial resposne using deconv method in the event-related design.
  5. However, getInstance(deconv) never outperform getInstance(mean), for both block design and event-related design!
  6. Mahalanobis performed badly, almost at chance level.
  7. In absolute terms, classification accuracy is similar for block and event-related designes, ~25% correct.

Notes on cinvor2 based on both contrast and orientation

In this version, instances are extracted by with regard to both its contrast and orientation. Theh classification are performed to decode orientation, separately for low and high contrast. Forward model were also built for orientation channels, separately for low and high contrast.

  1. Classification (on orientation) results are largley consistent with the results mentioned above (when collapsing across contrast).
  2. There is not much difference in classification accuracy between low and high contrast. One might expect high contrast to be classified better, but not quite the case here (there might be some minor improvements but subtle).
  3. For classification, two decon method were tried to get instances: 1-gamma fit and 2-gamma fit. 1-gamma seems to give better accuracy than 2-gamma, especially for block design (less so for event-related design), even though 2-gamma seems to fit the HRF better (judging from the figure shown by fitTimecourse).

Further things to consider

  1. in 8-way classification, shall we normalise the weights before combining the pairwise classifier output? (c.f. Kamitani & Tong, 2005)
  2. Mahal is not as good as Fisher (actually sometimes not good at all)–modification of how it's done?
  3. Maybe we can try an event-related design with ITI jitter; seems John's group have been doing that. It may give better estimates of single-trial response? –THIS HAS BEEN DONE, SEE ABOVE.