tfrStats.tfr_spw_stats_minmax module¶
- tfrStats.tfr_spw_stats_minmax.tfr_spw_stats_minmax(paths, cond, svar, fband, n_perm)[source]¶
Permutation based TFR statistical asessement based on min-max
Function to compute the truncated min-max distribution keeping the permutations for each condition and recording site. It captures the variations at the extreme of the null ditribution. In the min-max approach the minimum and maximum values at each permutations are used.
Todo
Implement onset shifting to account for whole trial (in the current example we pool values from the 400-1000 ms time window).
Implement compatibilityu with Syncopy (for now it relies on ftPool_… .mat containing the TFRs computed in Fieldtrip).
- Parameters:
input_path (string) – path to the .npz file.
condition (in) – condition index (i.e. 0, 1, 2, 3).
svar (int) – spectral power or GPR (not implemented here).
fband (int) – frequency band index (i.e. low, high, higher).
obs (int) – [nullType, percentile], two integeres: 0 for min-max, 1 for whole, 0-100 percentile.
correction (int) – 1 for p-values, 2 for cluster corrected p-values.
cluster_size (int) – cluster size.
alpha (float) – alpha.
- Returns:
empirical time frequency representation n_conds x n_sites x n_freqs x n_time (i.e. 30, 12, 16, 113).
- Returns:
null time frequency representation (i.e. 30, 12, 16, 113 or 1000, 30, 12, 16, 2).
- Return type:
float
@author: Nicolas Gravel, 19.09.2023