Stage 19: band-limited power in source space
19-kit_source_band_power.py localises oscillatory activity that is not
phase-locked to an event: alpha between a cue and the stimulus it announces,
beta around a movement. Such activity has a different phase in every trial,
so it cancels in the average and is absent from the evoked estimates of
stage 18. Its power does not cancel. This stage computes the power trial
by trial in source space, then averages it.
python 19-kit_source_band_power.py -c pipeline_config_files/attentionworden_config.yml [--overwrite] [--no-plots] [--no-movies]
It runs after stage 18 and reuses its work: the inverse operator of every
recording (same forward model, noise covariance, loose / depth and
method) and the morph to fsaverage. It adds outputs of its own and
changes nothing of the other stages. The group stages (21 and 22) work on the
evoked estimates only; the outputs of this stage are per subject.
Inputs: the stage-10 epochs (*_ev<code>_epo.fif), the stage-18 inverse
operators (*_desc-<method>_inv.fif) and the condition names of
events.conditions. Outputs, under
derivatives/19-kit_source_band_power/sub-<id>/:
<recording>_cond-<name>_band-<band>_desc-<method>power_space-fsaverage-{lh,rh}.stc: the power over time of one condition in one recording, averaged over the trials and the frequencies of the band, onfsaverage(not baseline-corrected);<recording>_band-<band>_desc-<method>power_trials.tsv: one row per trial with the power of the left and the right region in the analysis window and their lateralisation index;sub-<id>_cond-<name>_band-<band>_desc-<method>powerchange_space-fsaverage-{lh,rh}.stc: the subject’s map of a condition (recordings averaged with nave weights), as the percent change from the baseline window;sub-<id>_contrast-<name>_band-<band>_desc-<method>powermodulation_space-fsaverage-{lh,rh}.stc: the modulation index 100 (a - b) / (a + b) of a contrast;sub-<id>_band-<band>_desc-regions.tsvandfigures/sub-<id>_band-<band>_desc-regions.png: the time course of the power in the two regions per condition, and the lateralisation index over time;sub-<id>_contrast-<name>_band-<band>_desc-lateralisation.json: the comparison of the trial-wise lateralisation index between the two sides of the contrast;for every subject map:
*_frames/,*_slider.html,*_movie.mp4(or.gif) and*_desc-peakframe.png, rendered by the functions of stage 24 with thesource.moviessettings;source_band_power_summary.csv: one row per subject, band and condition or contrast.
What it does
Power per trial, per recording (
mne.minimum_norm.source_band_induced_power). Every epoch is convolved with Morlet wavelets at the frequencies of the band (freq_step_hzapart,n_cyclescycles each), the result is projected through the inverse operator withlambda2 = 1 / snr**2, the power of the three source orientations is summed, and the power is averaged over the frequencies and over the trials.snris lower than in stage 18 (1 instead of 3) because single trials are noisier than their average. Withsubtract_evoked: truethe average response is removed from every trial first, which leaves the induced power only; by default the power is the total power, evoked part included. The first and lastcrop_edges_sof the epoch, where the wavelets reach beyond the data, are dropped. The estimate is morphed tofsaverage.One map per subject and condition. The recordings of a subject are averaged with nave weights, as stages 21 and 24 do for the evoked estimates. The map is then expressed as the percent change from the mean power in
baseline.window, at every source. Without a baseline window no condition map is written (the contrasts do not need one).Contrasts within the subject. For each contrast
aminusb(contrasts, orsource.group.contrastswhennull) the modulation index 100 (a - b) / (a + b) is computed from the power itself. It is zero where the two conditions have the same power and needs no baseline, which matters when the question is about the period before an event.Two regions and their lateralisation.
lateralisation.labelsnames labels of the parcellationsource.inverse.labels.parc; they are merged into one region per hemisphere. The figure shows the power of each region over time and the lateralisation index LI = (R - L) / (R + L). For the statistics the power of the two regions is computed for every trial inlateralisation.window(mne.minimum_norm.compute_source_psd_epochson the cropped epochs, in the anatomy of the subject, averaged over the band and over the vertices of the region), which gives one LI per trial. The trials ofaand ofbof all recordings are then compared: Welch t-test, a permutation test of the difference of the means (n_permutations,seed) and Cohen’s d. The log power of each region is compared in the same way, which shows which hemisphere carries a difference. These are tests over the trials of one subject; they say nothing about a population.Movies. Each subject map is rendered over time by the functions of stage 24, with a diverging colour scale because the maps are signed (red: more power than at baseline, or more in
athan inb).
Configuration
source:
band_power:
enabled: true
conditions: [cue_left, cue_right] # [] = every condition with stage-10 epochs
contrasts: null # null = source.group.contrasts
bands: {alpha: [8, 14]}
freq_step_hz: 1.0
n_cycles: 4
snr: 1.0
decim: 20
subtract_evoked: false
crop_edges_s: 0.1
baseline: {window: [-0.4, -0.1]}
lateralisation:
enabled: true
labels: [lateraloccipital, cuneus, pericalcarine, lingual]
window: [0.775, 1.025]
n_permutations: 5000
seed: 97
movies: true
save_plots: true
n_jobs: 1
Reuse: a recording is recomputed when its epochs or its inverse operator
changed, when the settings changed, or with --overwrite. The subject
maps are rebuilt from the recordings at every run; the movies are re-rendered
only when the maps or the source.movies settings changed.
Reading the result
The condition maps answer “where does the power rise or fall after the event, relative to before it”. Expect a decrease over the sensory cortex that processes a stimulus.
The contrast map answers “where does the power differ between the two conditions”. It is noisy with few trials: individual sources are not tested, so read the regions and the trial-wise comparison for a decision.
A wavelet of 4 cycles at 8 Hz is about a quarter of a second long, so the maps are smooth in time by that much: a change that seems to start before an event is partly this smoothing.