Statistics#

mne.stats:

Functions for statistical analysis.

Parametric statistics (see scipy.stats and statsmodels for more options):

ttest_1samp_no_p(X[, sigma, method])

Perform one-sample t-test.

ttest_ind_no_p(a, b[, equal_var, sigma])

Independent samples t-test without p calculation.

f_oneway(*args)

Perform a 1-way ANOVA.

f_mway_rm(data, factor_levels[, effects, ...])

Compute M-way repeated measures ANOVA for fully balanced designs.

f_threshold_mway_rm(n_subjects, factor_levels)

Compute F-value thresholds for a two-way ANOVA.

linear_regression(inst, design_matrix[, names])

Fit Ordinary Least Squares (OLS) regression.

linear_regression_raw(raw, events[, ...])

Estimate regression-based evoked potentials/fields by linear modeling.

Mass-univariate multiple comparison correction:

bonferroni_correction(pval[, alpha])

P-value correction with Bonferroni method.

fdr_correction(pvals[, alpha, method])

P-value correction with False Discovery Rate (FDR).

Non-parametric (clustering) resampling methods:

combine_adjacency(*structure)

Create a sparse binary adjacency/neighbors matrix.

permutation_cluster_test(X[, threshold, ...])

Cluster-level statistical permutation test.

permutation_cluster_1samp_test(X[, ...])

Non-parametric cluster-level paired t-test.

permutation_t_test(X[, n_permutations, ...])

One sample/paired sample permutation test based on a t-statistic.

spatio_temporal_cluster_test(X[, threshold, ...])

Non-parametric cluster-level test for spatio-temporal data.

spatio_temporal_cluster_1samp_test(X[, ...])

Non-parametric cluster-level paired t-test for spatio-temporal data.

summarize_clusters_stc(clu[, p_thresh, ...])

Assemble summary SourceEstimate from spatiotemporal cluster results.

bootstrap_confidence_interval(arr[, ci, ...])

Get confidence intervals from non-parametric bootstrap.

ERP-related statistics:

erp.compute_sme(epochs[, start, stop])

Compute standardized measurement error (SME).

Compute adjacency matrices for cluster-level statistics:

channels.find_ch_adjacency(info, ch_type)

Find the adjacency matrix for the given channels.

channels.read_ch_adjacency(fname[, picks])

Read a channel adjacency ("neighbors") file that ships with MNE.

spatial_dist_adjacency(src, dist[, verbose])

Compute adjacency from distances in a source space.

spatial_src_adjacency(src[, dist, verbose])

Compute adjacency for a source space activation.

spatial_tris_adjacency(tris[, ...])

Compute adjacency from triangles.

spatial_inter_hemi_adjacency(src, dist[, ...])

Get vertices on each hemisphere that are close to the other hemisphere.

spatio_temporal_src_adjacency(src, n_times)

Compute adjacency for a source space activation over time.

spatio_temporal_tris_adjacency(tris, n_times)

Compute adjacency from triangles and time instants.

spatio_temporal_dist_adjacency(src, n_times, ...)

Compute adjacency from distances in a source space and time instants.