This folder contains example scripts for plotting cortical activation figures
using the data associated with the paper "Spatio-temporal progression of
cortical activity related to continuous overt and covert speech production in a
reading task." 

The sub-folder Data contains all the ECoG band powers from the overt and covert
conditions for all eight subjects and the speech power recorded during the overt
condition for the eight subjects.

Code:

The file Main.m is the main script that computes and plots -log p values from
correlating the gamma band powers and speech powers for all eight subjects. This
code only plots example cortical plots for the time latencies that were used in
the article (Figure 4 (b)). However, the time latencies can be changed to plot
other  time latencies of interest to the investigator. 

This file calls two functions scrambledpvalue.m (for computing the -log p
values) and tickerplots.m (for plotting the activations on cortical plots).

tickerplots.m further calls the function activateBrain.m for visualizing the
cortical activations on a brain model. 

This folder also contains two files ALL_brain.mat and ALL_Electrodes_linear.mat
which correspond to the generic averaged head brain model used for plotting, and
the electrode mappings to this head model, respectively. These two files are
loaded in by the activateBrain.m function and are used for plotting the -logp
values on the brain model. 

Note that the path in MATLAB must be set to this folder prior to running the
code Main.m for successful execution of the code.