Jump to content

User Tutorial:Performing an Offline Analysis of ECoG Data

From BCI2000 Wiki

In this section of the tutorial, we perform a similar offline analysis of a dataset recorded using an ECoG. As in the case of EEG data, we expect the basic properties of the Mu rhythm to be identical for all humans, while the rhythm's spatial pattern and exact frequency range will differ. BCI2000 Offline Analysis helps to determine the frequencies and locations that correlate best with a given instruction.

Experimental Design

This tutorial will make use of the ecog1_1.dat and ecog1_2.dat sessions that are included with BCI2000 and can be found in data/samplefiles/. In these sessions, the subject was asked to move each hand in a predefined pattern. The resulting data was recorded using BCI2000 and labeled using the StimulusCode state variable such that TargetCode is equal to 1 when the subject is responding to the instruction to move his/her left hand, 2 when the subject is responding to the instruction to move his/her right hand and 0 when the subject is responding to the instruction to rest. If you are relatively new to BCI2000, you may find it helpful to inspect the data files we'll be using with the BCI2000 Viewer. Using this tool, you will be able to see how state variables change with respect to the data over time. For instruction on how to inspect data using the BCI2000 Viewer, please see User Reference:BCI2000Viewer.

The Results

In User Tutorial:Performing an Offline Analysis of EEG Data we manually entered all the analysis parameters. In this tutorial we will make use of a useful feature of BCI2000 Offline Analysis - loading previously saved settings. In order to load the settings for this tutorial, please do the following:

  1. Click File>Load Settings
  2. Navigate to data/samplefiles/
  3. Double-click or otherwise open ecog1Analysis.bws

At this point BCI2000 Offline Analysis should look like this:

Now, click "Generate Plots". Once your analysis is complete, you should see feature, spectra and topography plots similar to the plots below:

In designing this analysis, we followed a similar procedure to the procedure outlined in User Tutorial:Performing an Offline Analysis of EEG Data. First, we can see distinct clusters of high r-squared values in the feature plot. Again, these clusters are typically the first indication that the frequency/channel pairs that comprise the cluster may be good features for on-line analysis. In the generated feature plot, we see that one of the clusters with the highest r-squared values is centered around (25 Hz, Channel 14). So, we continue by creating a topography at 25 Hz and a spectra for channel 14. In the previous tutorial, we used these plots to evaluate the physiological plausibility of this response. We first note that there are significant changes in the spectra between movement and rest. Also, the most significant of these changes occur around the beta frequency range. From the topography, we see that the response is