Python API Reference#
This is the reference for classes (CamelCase
names) and functions
(underscore_case
names) of MNE-Python, grouped thematically by analysis
stage. Functions and classes that are not
below a module heading are found in the mne
namespace.
MNE-Python also provides multiple command-line scripts that can be called directly from a terminal, see Command line tools using Python.
mne
:
MNE software for MEG and EEG data analysis.
- Most-used classes
- Reading raw data
- mne.io.anonymize_info
- mne.io.read_raw
- mne.io.read_raw_artemis123
- mne.io.read_raw_bti
- mne.io.read_raw_cnt
- mne.io.read_raw_ctf
- mne.io.read_raw_curry
- mne.io.read_raw_edf
- mne.io.read_raw_eyelink
- mne.io.read_raw_bdf
- mne.io.read_raw_gdf
- mne.io.read_raw_kit
- mne.io.read_raw_nedf
- mne.io.read_raw_nicolet
- mne.io.read_raw_hitachi
- mne.io.read_raw_nirx
- mne.io.read_raw_snirf
- mne.io.read_raw_eeglab
- mne.io.read_raw_brainvision
- mne.io.read_raw_egi
- mne.io.read_raw_fif
- mne.io.read_raw_eximia
- mne.io.read_raw_fieldtrip
- mne.io.read_raw_boxy
- mne.io.read_raw_persyst
- mne.io.read_raw_nihon
- mne.io.read_raw_fil
- mne.io.BaseRaw
- mne.io.kit.read_mrk
- File I/O
- mne.channel_type
- mne.channel_indices_by_type
- mne.get_head_surf
- mne.get_meg_helmet_surf
- mne.get_volume_labels_from_aseg
- mne.get_volume_labels_from_src
- mne.parse_config
- mne.read_labels_from_annot
- mne.read_bem_solution
- mne.read_bem_surfaces
- mne.read_cov
- mne.read_dipole
- mne.read_epochs
- mne.read_epochs_kit
- mne.read_epochs_eeglab
- mne.read_epochs_fieldtrip
- mne.read_events
- mne.read_evokeds
- mne.read_evoked_besa
- mne.read_evoked_fieldtrip
- mne.read_evokeds_mff
- mne.read_freesurfer_lut
- mne.read_forward_solution
- mne.read_label
- mne.read_morph_map
- mne.read_proj
- mne.read_reject_parameters
- mne.read_source_estimate
- mne.read_source_spaces
- mne.read_surface
- mne.read_trans
- mne.read_tri
- mne.write_labels_to_annot
- mne.write_bem_solution
- mne.write_bem_surfaces
- mne.write_head_bem
- mne.write_cov
- mne.write_events
- mne.write_evokeds
- mne.write_forward_solution
- mne.write_label
- mne.write_proj
- mne.write_source_spaces
- mne.write_surface
- mne.write_trans
- mne.what
- mne.io.read_info
- mne.io.show_fiff
- mne.BaseEpochs
- Creating data objects from arrays
- Exporting
- Datasets
- mne.datasets.fetch_dataset
- mne.datasets.has_dataset
- mne.datasets.brainstorm.bst_auditory.data_path
- mne.datasets.brainstorm.bst_resting.data_path
- mne.datasets.brainstorm.bst_raw.data_path
- mne.datasets.eegbci.load_data
- mne.datasets.eegbci.standardize
- mne.datasets.fetch_aparc_sub_parcellation
- mne.datasets.fetch_fsaverage
- mne.datasets.fetch_hcp_mmp_parcellation
- mne.datasets.fetch_infant_template
- mne.datasets.fetch_phantom
- mne.datasets.fnirs_motor.data_path
- mne.datasets.hf_sef.data_path
- mne.datasets.kiloword.data_path
- mne.datasets.limo.load_data
- mne.datasets.misc.data_path
- mne.datasets.mtrf.data_path
- mne.datasets.multimodal.data_path
- mne.datasets.opm.data_path
- mne.datasets.sleep_physionet.age.fetch_data
- mne.datasets.sleep_physionet.temazepam.fetch_data
- mne.datasets.sample.data_path
- mne.datasets.somato.data_path
- mne.datasets.spm_face.data_path
- mne.datasets.ucl_opm_auditory.data_path
- mne.datasets.visual_92_categories.data_path
- mne.datasets.phantom_4dbti.data_path
- mne.datasets.refmeg_noise.data_path
- mne.datasets.ssvep.data_path
- mne.datasets.erp_core.data_path
- mne.datasets.epilepsy_ecog.data_path
- mne.datasets.eyelink.data_path
- Visualization
- mne.viz.Brain
- mne.viz.ClickableImage
- mne.viz.Figure3D
- mne.viz.add_background_image
- mne.viz.centers_to_edges
- mne.viz.compare_fiff
- mne.viz.circular_layout
- mne.viz.iter_topography
- mne.viz.mne_analyze_colormap
- mne.viz.plot_bem
- mne.viz.plot_brain_colorbar
- mne.viz.plot_bridged_electrodes
- mne.viz.plot_chpi_snr
- mne.viz.plot_cov
- mne.viz.plot_channel_labels_circle
- mne.viz.plot_ch_adjacency
- mne.viz.plot_csd
- mne.viz.plot_dipole_amplitudes
- mne.viz.plot_dipole_locations
- mne.viz.plot_drop_log
- mne.viz.plot_epochs
- mne.viz.plot_epochs_psd_topomap
- mne.viz.plot_events
- mne.viz.plot_evoked
- mne.viz.plot_evoked_image
- mne.viz.plot_evoked_topo
- mne.viz.plot_evoked_topomap
- mne.viz.plot_evoked_joint
- mne.viz.plot_evoked_field
- mne.viz.plot_evoked_white
- mne.viz.plot_filter
- mne.viz.plot_head_positions
- mne.viz.plot_ideal_filter
- mne.viz.plot_compare_evokeds
- mne.viz.plot_ica_sources
- mne.viz.plot_ica_components
- mne.viz.plot_ica_properties
- mne.viz.plot_ica_scores
- mne.viz.plot_ica_overlay
- mne.viz.plot_epochs_image
- mne.viz.plot_layout
- mne.viz.plot_montage
- mne.viz.plot_projs_topomap
- mne.viz.plot_projs_joint
- mne.viz.plot_raw
- mne.viz.plot_raw_psd
- mne.viz.plot_regression_weights
- mne.viz.plot_sensors
- mne.viz.plot_snr_estimate
- mne.viz.plot_source_estimates
- mne.viz.link_brains
- mne.viz.plot_volume_source_estimates
- mne.viz.plot_vector_source_estimates
- mne.viz.plot_sparse_source_estimates
- mne.viz.plot_tfr_topomap
- mne.viz.plot_topo_image_epochs
- mne.viz.plot_topomap
- mne.viz.plot_alignment
- mne.viz.snapshot_brain_montage
- mne.viz.plot_arrowmap
- mne.viz.set_3d_backend
- mne.viz.get_3d_backend
- mne.viz.use_3d_backend
- mne.viz.set_3d_options
- mne.viz.set_3d_view
- mne.viz.set_3d_title
- mne.viz.create_3d_figure
- mne.viz.close_3d_figure
- mne.viz.close_all_3d_figures
- mne.viz.get_brain_class
- mne.viz.set_browser_backend
- mne.viz.get_browser_backend
- mne.viz.use_browser_backend
- Preprocessing
- mne.Projection
- mne.compute_proj_epochs
- mne.compute_proj_evoked
- mne.compute_proj_raw
- mne.read_proj
- mne.write_proj
- mne.channels.Layout
- mne.channels.DigMontage
- mne.channels.compute_native_head_t
- mne.channels.fix_mag_coil_types
- mne.channels.read_polhemus_fastscan
- mne.channels.get_builtin_montages
- mne.channels.make_dig_montage
- mne.channels.read_dig_polhemus_isotrak
- mne.channels.read_dig_captrak
- mne.channels.read_dig_dat
- mne.channels.read_dig_egi
- mne.channels.read_dig_fif
- mne.channels.read_dig_hpts
- mne.channels.read_dig_localite
- mne.channels.make_standard_montage
- mne.channels.read_custom_montage
- mne.channels.compute_dev_head_t
- mne.channels.read_layout
- mne.channels.find_layout
- mne.channels.make_eeg_layout
- mne.channels.make_grid_layout
- mne.channels.find_ch_adjacency
- mne.channels.get_builtin_ch_adjacencies
- mne.channels.read_ch_adjacency
- mne.channels.equalize_channels
- mne.channels.rename_channels
- mne.channels.generate_2d_layout
- mne.channels.make_1020_channel_selections
- mne.channels.combine_channels
- mne.preprocessing.ICA
- mne.preprocessing.Xdawn
- mne.preprocessing.EOGRegression
- mne.preprocessing.annotate_amplitude
- mne.preprocessing.annotate_break
- mne.preprocessing.annotate_movement
- mne.preprocessing.annotate_muscle_zscore
- mne.preprocessing.annotate_nan
- mne.preprocessing.compute_average_dev_head_t
- mne.preprocessing.compute_current_source_density
- mne.preprocessing.compute_bridged_electrodes
- mne.preprocessing.compute_fine_calibration
- mne.preprocessing.compute_maxwell_basis
- mne.preprocessing.compute_proj_ecg
- mne.preprocessing.compute_proj_eog
- mne.preprocessing.compute_proj_hfc
- mne.preprocessing.cortical_signal_suppression
- mne.preprocessing.create_ecg_epochs
- mne.preprocessing.create_eog_epochs
- mne.preprocessing.find_bad_channels_maxwell
- mne.preprocessing.find_ecg_events
- mne.preprocessing.find_eog_events
- mne.preprocessing.fix_stim_artifact
- mne.preprocessing.ica_find_ecg_events
- mne.preprocessing.ica_find_eog_events
- mne.preprocessing.infomax
- mne.preprocessing.interpolate_bridged_electrodes
- mne.preprocessing.equalize_bads
- mne.preprocessing.maxwell_filter
- mne.preprocessing.maxwell_filter_prepare_emptyroom
- mne.preprocessing.oversampled_temporal_projection
- mne.preprocessing.peak_finder
- mne.preprocessing.read_ica
- mne.preprocessing.read_eog_regression
- mne.preprocessing.realign_raw
- mne.preprocessing.regress_artifact
- mne.preprocessing.corrmap
- mne.preprocessing.read_ica_eeglab
- mne.preprocessing.read_fine_calibration
- mne.preprocessing.write_fine_calibration
- mne.preprocessing.nirs.optical_density
- mne.preprocessing.nirs.beer_lambert_law
- mne.preprocessing.nirs.source_detector_distances
- mne.preprocessing.nirs.short_channels
- mne.preprocessing.nirs.scalp_coupling_index
- mne.preprocessing.nirs.temporal_derivative_distribution_repair
- mne.preprocessing.ieeg.project_sensors_onto_brain
- mne.preprocessing.ieeg.make_montage_volume
- mne.preprocessing.ieeg.warp_montage
- mne.preprocessing.eyetracking.set_channel_types_eyetrack
- mne.add_reference_channels
- mne.set_bipolar_reference
- mne.set_eeg_reference
- mne.filter.construct_iir_filter
- mne.filter.create_filter
- mne.filter.estimate_ringing_samples
- mne.filter.filter_data
- mne.filter.notch_filter
- mne.filter.resample
- mne.chpi.compute_chpi_amplitudes
- mne.chpi.compute_chpi_snr
- mne.chpi.compute_chpi_locs
- mne.chpi.compute_head_pos
- mne.chpi.extract_chpi_locs_ctf
- mne.chpi.extract_chpi_locs_kit
- mne.chpi.filter_chpi
- mne.chpi.get_active_chpi
- mne.chpi.get_chpi_info
- mne.chpi.head_pos_to_trans_rot_t
- mne.chpi.read_head_pos
- mne.chpi.write_head_pos
- mne.transforms.Transform
- mne.transforms.quat_to_rot
- mne.transforms.rot_to_quat
- mne.transforms.read_ras_mni_t
- Events
- mne.Annotations
- mne.AcqParserFIF
- mne.concatenate_events
- mne.count_events
- mne.find_events
- mne.find_stim_steps
- mne.make_fixed_length_events
- mne.make_fixed_length_epochs
- mne.merge_events
- mne.parse_config
- mne.pick_events
- mne.read_annotations
- mne.read_events
- mne.write_events
- mne.concatenate_epochs
- mne.events_from_annotations
- mne.annotations_from_events
- mne.event.define_target_events
- mne.event.match_event_names
- mne.event.shift_time_events
- mne.epochs.average_movements
- mne.epochs.combine_event_ids
- mne.epochs.equalize_epoch_counts
- mne.epochs.make_metadata
- Sensor Space Data
- mne.combine_evoked
- mne.concatenate_raws
- mne.equalize_channels
- mne.grand_average
- mne.match_channel_orders
- mne.pick_channels
- mne.pick_channels_cov
- mne.pick_channels_forward
- mne.pick_channels_regexp
- mne.pick_types
- mne.pick_types_forward
- mne.pick_info
- mne.read_epochs
- mne.read_reject_parameters
- mne.read_vectorview_selection
- mne.rename_channels
- mne.baseline.rescale
- Covariance computation
- MRI Processing
- mne.coreg.get_mni_fiducials
- mne.coreg.estimate_head_mri_t
- mne.io.read_fiducials
- mne.io.write_fiducials
- mne.get_montage_volume_labels
- mne.gui.coregistration
- mne.gui.locate_ieeg
- mne.create_default_subject
- mne.head_to_mni
- mne.head_to_mri
- mne.read_freesurfer_lut
- mne.read_lta
- mne.read_talxfm
- mne.scale_mri
- mne.scale_bem
- mne.scale_labels
- mne.scale_source_space
- mne.transforms.apply_volume_registration
- mne.transforms.apply_volume_registration_points
- mne.transforms.compute_volume_registration
- mne.vertex_to_mni
- mne.coreg.Coregistration
- Forward Modeling
- mne.Forward
- mne.SourceSpaces
- mne.add_source_space_distances
- mne.apply_forward
- mne.apply_forward_raw
- mne.average_forward_solutions
- mne.convert_forward_solution
- mne.decimate_surface
- mne.dig_mri_distances
- mne.forward.compute_depth_prior
- mne.forward.compute_orient_prior
- mne.forward.restrict_forward_to_label
- mne.forward.restrict_forward_to_stc
- mne.make_bem_model
- mne.make_bem_solution
- mne.make_forward_dipole
- mne.make_forward_solution
- mne.make_field_map
- mne.make_sphere_model
- mne.morph_source_spaces
- mne.read_bem_surfaces
- mne.read_forward_solution
- mne.read_trans
- mne.read_source_spaces
- mne.read_surface
- mne.sensitivity_map
- mne.setup_source_space
- mne.setup_volume_source_space
- mne.surface.complete_surface_info
- mne.surface.read_curvature
- mne.use_coil_def
- mne.write_bem_surfaces
- mne.write_trans
- mne.bem.ConductorModel
- mne.bem.fit_sphere_to_headshape
- mne.bem.get_fitting_dig
- mne.bem.make_watershed_bem
- mne.bem.make_flash_bem
- mne.bem.make_scalp_surfaces
- mne.bem.convert_flash_mris
- mne.bem.distance_to_bem
- Inverse Solutions
- mne.minimum_norm.InverseOperator
- mne.minimum_norm.apply_inverse
- mne.minimum_norm.apply_inverse_cov
- mne.minimum_norm.apply_inverse_epochs
- mne.minimum_norm.apply_inverse_raw
- mne.minimum_norm.apply_inverse_tfr_epochs
- mne.minimum_norm.compute_source_psd
- mne.minimum_norm.compute_source_psd_epochs
- mne.minimum_norm.compute_rank_inverse
- mne.minimum_norm.estimate_snr
- mne.minimum_norm.make_inverse_operator
- mne.minimum_norm.prepare_inverse_operator
- mne.minimum_norm.read_inverse_operator
- mne.minimum_norm.source_band_induced_power
- mne.minimum_norm.source_induced_power
- mne.minimum_norm.write_inverse_operator
- mne.minimum_norm.make_inverse_resolution_matrix
- mne.minimum_norm.resolution_metrics
- mne.minimum_norm.get_cross_talk
- mne.minimum_norm.get_point_spread
- mne.inverse_sparse.mixed_norm
- mne.inverse_sparse.tf_mixed_norm
- mne.inverse_sparse.gamma_map
- mne.inverse_sparse.make_stc_from_dipoles
- mne.beamformer.Beamformer
- mne.beamformer.read_beamformer
- mne.beamformer.make_lcmv
- mne.beamformer.apply_lcmv
- mne.beamformer.apply_lcmv_epochs
- mne.beamformer.apply_lcmv_raw
- mne.beamformer.apply_lcmv_cov
- mne.beamformer.make_dics
- mne.beamformer.apply_dics
- mne.beamformer.apply_dics_csd
- mne.beamformer.apply_dics_epochs
- mne.beamformer.apply_dics_tfr_epochs
- mne.beamformer.rap_music
- mne.beamformer.trap_music
- mne.beamformer.make_lcmv_resolution_matrix
- mne.Dipole
- mne.DipoleFixed
- mne.fit_dipole
- mne.dipole.get_phantom_dipoles
- Source Space Data
- mne.BiHemiLabel
- mne.Label
- mne.MixedSourceEstimate
- mne.MixedVectorSourceEstimate
- mne.SourceEstimate
- mne.VectorSourceEstimate
- mne.VolSourceEstimate
- mne.VolVectorSourceEstimate
- mne.SourceMorph
- mne.compute_source_morph
- mne.extract_label_time_course
- mne.grade_to_tris
- mne.grade_to_vertices
- mne.label.select_sources
- mne.grow_labels
- mne.label_sign_flip
- mne.labels_to_stc
- mne.morph_labels
- mne.random_parcellation
- mne.read_labels_from_annot
- mne.read_dipole
- mne.read_label
- mne.read_source_estimate
- mne.read_source_morph
- mne.split_label
- mne.stc_to_label
- mne.stc_near_sensors
- mne.transform_surface_to
- mne.write_labels_to_annot
- mne.write_label
- mne.source_space.compute_distance_to_sensors
- mne.source_space.get_decimated_surfaces
- Time-Frequency
- mne.time_frequency.AverageTFR
- mne.time_frequency.EpochsTFR
- mne.time_frequency.CrossSpectralDensity
- mne.time_frequency.Spectrum
- mne.time_frequency.EpochsSpectrum
- mne.time_frequency.csd_tfr
- mne.time_frequency.csd_fourier
- mne.time_frequency.csd_multitaper
- mne.time_frequency.csd_morlet
- mne.time_frequency.pick_channels_csd
- mne.time_frequency.read_csd
- mne.time_frequency.fit_iir_model_raw
- mne.time_frequency.tfr_morlet
- mne.time_frequency.tfr_multitaper
- mne.time_frequency.tfr_stockwell
- mne.time_frequency.read_tfrs
- mne.time_frequency.write_tfrs
- mne.time_frequency.read_spectrum
- mne.time_frequency.csd_array_fourier
- mne.time_frequency.csd_array_multitaper
- mne.time_frequency.csd_array_morlet
- mne.time_frequency.dpss_windows
- mne.time_frequency.fwhm
- mne.time_frequency.morlet
- mne.time_frequency.stft
- mne.time_frequency.istft
- mne.time_frequency.stftfreq
- mne.time_frequency.psd_array_multitaper
- mne.time_frequency.psd_array_welch
- mne.time_frequency.tfr_array_morlet
- mne.time_frequency.tfr_array_multitaper
- mne.time_frequency.tfr_array_stockwell
- mne.time_frequency.tfr.cwt
- mne.time_frequency.tfr.morlet
- Connectivity Estimation
- Statistics
- mne.stats.ttest_1samp_no_p
- mne.stats.ttest_ind_no_p
- mne.stats.f_oneway
- mne.stats.f_mway_rm
- mne.stats.f_threshold_mway_rm
- mne.stats.linear_regression
- mne.stats.linear_regression_raw
- mne.stats.bonferroni_correction
- mne.stats.fdr_correction
- mne.stats.combine_adjacency
- mne.stats.permutation_cluster_test
- mne.stats.permutation_cluster_1samp_test
- mne.stats.permutation_t_test
- mne.stats.spatio_temporal_cluster_test
- mne.stats.spatio_temporal_cluster_1samp_test
- mne.stats.summarize_clusters_stc
- mne.stats.bootstrap_confidence_interval
- mne.channels.find_ch_adjacency
- mne.channels.read_ch_adjacency
- mne.spatial_dist_adjacency
- mne.spatial_src_adjacency
- mne.spatial_tris_adjacency
- mne.spatial_inter_hemi_adjacency
- mne.spatio_temporal_src_adjacency
- mne.spatio_temporal_tris_adjacency
- mne.spatio_temporal_dist_adjacency
- Simulation
- mne.simulation.add_chpi
- mne.simulation.add_ecg
- mne.simulation.add_eog
- mne.simulation.add_noise
- mne.simulation.simulate_evoked
- mne.simulation.simulate_raw
- mne.simulation.simulate_stc
- mne.simulation.simulate_sparse_stc
- mne.simulation.select_source_in_label
- mne.simulation.SourceSimulator
- mne.simulation.metrics.cosine_score
- mne.simulation.metrics.region_localization_error
- mne.simulation.metrics.f1_score
- mne.simulation.metrics.precision_score
- mne.simulation.metrics.recall_score
- mne.simulation.metrics.roc_auc_score
- mne.simulation.metrics.spatial_deviation_error
- mne.simulation.metrics.peak_position_error
- Decoding
- mne.decoding.CSP
- mne.decoding.EMS
- mne.decoding.FilterEstimator
- mne.decoding.LinearModel
- mne.decoding.PSDEstimator
- mne.decoding.Scaler
- mne.decoding.TemporalFilter
- mne.decoding.TimeFrequency
- mne.decoding.UnsupervisedSpatialFilter
- mne.decoding.Vectorizer
- mne.decoding.ReceptiveField
- mne.decoding.TimeDelayingRidge
- mne.decoding.SlidingEstimator
- mne.decoding.GeneralizingEstimator
- mne.decoding.SPoC
- mne.decoding.SSD
- mne.decoding.compute_ems
- mne.decoding.cross_val_multiscore
- mne.decoding.get_coef
- Realtime
- MNE-Report
- Logging and Configuration