 # (EEG Analysis) Comparing scalp topographical distributions of theta activity across multiple conditions

Dear MNE-Python community,

Thank you for having built this great Python package!

I am a student with little experience in the area of EEG analysis. I am currently working on my master thesis. I conducted an EEG experiment with three different conditions (A, B and C). Every participant was exposed to all three conditions (sequentially). I would like to find out whether the different conditions involved different scalp topographical distributions of theta oscillations. I hypothesise (among other things) that participants’ theta activity in condition C was dispersed over a wider brain area than their theta activity in conditions A and B. I am trying to test this hypothesis, but I am experiencing some difficulties. I hope you can help me. My apologies if any of my questions seem silly.

I am currently taking the following steps:

1. For each participant, I identify all bad channels and I apply independent components analysis (ICA). I have one data file per participant.
2. For each participant, I extract epochs from that participant’s data file.
3. For each participant, I ‘average the epochs for each condition’. Example: `conditionAverage_A = epochs[‘A’].average()`.
4. For each condition, I create a list that contains all participant ‘averages’ for that condition. Example: `participantAverages_A = [conditionAverage_A_P1, conditionAverage_A_P2, …]`.
5. For each condition, I average all participant ‘averages’ for that condition. I call the resulting averages (evoked data) ‘sample averages’. For example: `sampleAverage_A = mne.combine_evoked(participantAverages_A, weights= 'equal')`.

I now have three ‘sample averages’, one for each condition. I would like to do two more things.

[1/2] First of all, for each ‘sample average’, I would like to produce a topomap that ‘displays theta activity’. (I currently define theta activity as activity in the 4 to 7Hz range.) For sampleAverage_A, for instance, I would like to produce a map similar to the one that `epochs[‘A’].plot_psd_topomap(ch_type='eeg', bands=[(4,7,'Theta’)])` would produce for a single participants’ epochs for condition A (please see figure 1 below; code adapted from the tutorial ‘Visualizing epoched data’). Unfortunately, the `plot_psd_topomap` function does not work for evoked data. I tried to work my way around this by using the following code (adapted from the tutorial ‘Frequency and time-frequency sensor analysis’; I do not understand every aspect of this code yet).

``````freqs = [4, 7]
power = tfr_morlet(sampleAverages[condition], freqs=freqs, n_cycles = 1, use_fft=True, return_itc=False)
power.plot_topomap(ch_type= 'eeg' , tmin = 0, tmax = 1, fmin=4, fmax=7, mode= 'mean' , show_names=True,
baseline=(None, None), title= ‘Condition A (Theta)’ , show=True)
``````

The result can be found in figure 2 below . Is there perhaps a way to get an image that is even more similar to the one produced by the `plot_psd_topomap` function?

[2/2] Secondly, I would also like to statistically examine whether participants’ theta activity was more widely distributed in condition C than it was in conditions A and B. I currently think the ‘Permutation t-test on source data with spatio-temporal clustering’ tutorial would be most relevant tutorial for me to look at, but I lack the experience required to assess whether that is indeed correct. Could you perhaps tell me whether or not I am on the right track, and if not, could you perhaps point me to the tutorial that you think would be most relevant for me?