Skip to main content

A simplified MNE-Python wrapper for teaching EEG analysis

Project description

mini-mne

A simplified wrapper around MNE-Python for teaching EEG data analysis. mini-mne exposes only the essential classes and methods, reducing the cognitive load for learners who are new to EEG preprocessing and analysis.

Installation

pip install --upgrade mini-mne

Requires Python ≥ 3.11.

Usage

mini-mne follows the standard EEG analysis pipeline: load continuous data → epoch around events → compute ERPs.

from mini_mne import SimpleRaw, SimpleEpoch, SimpleEvoked, plot_evokeds

# Load data (downloads the MNE ERP-CORE example dataset if no path is given)
raw = SimpleRaw()

# Inspect the data
print(raw)
print(raw.sampling_frequency)  # Hz
print(raw.channel_names)
print(raw.duration)            # seconds

# Preprocess
raw = raw.filter(l_freq=0.1, h_freq=40.0)
raw = raw.re_reference()

# Extract events from annotations
events, event_id = raw.get_events()

# Epoch the data
epochs = SimpleEpoch(raw, events, event_id,
                     tmin=-0.2, tmax=0.8,
                     baseline=(-0.2, 0),
                     reject={"eeg": 100e-6})

print(epochs)
print(epochs.event_types)
print(epochs.dropped_epochs)

# Compute ERPs
evokeds = epochs.average(by_event_type=True)

# Plot
plot_evokeds(evokeds)

Classes

Class Wraps Purpose
SimpleRaw mne.io.Raw Continuous EEG data
SimpleEpoch mne.Epochs Segmented data around events
SimpleEvoked mne.Evoked Averaged ERP

Licence

mini-mne is licenced under the BSD-3-Clause licence.

Acknowledgements

mini-mne is built on top of MNE-Python. The default example dataset is from the ERP-CORE dataset (Kappenman et al., 2021).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mini_mne-0.1.3.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mini_mne-0.1.3-py3-none-any.whl (7.5 kB view details)

Uploaded Python 3

File details

Details for the file mini_mne-0.1.3.tar.gz.

File metadata

  • Download URL: mini_mne-0.1.3.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.3 {"installer":{"name":"uv","version":"0.11.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for mini_mne-0.1.3.tar.gz
Algorithm Hash digest
SHA256 9bd01c9e1b2e40bbf44d70ac133143c6d5a99e6119ef2f9c753a9cab483c63a5
MD5 b20080022c72e60900230b297d02bf37
BLAKE2b-256 16b27a636daeb2efc284894b9d3b77592f8fe18ead1cad7f394a727dd5276f85

See more details on using hashes here.

File details

Details for the file mini_mne-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: mini_mne-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 7.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.3 {"installer":{"name":"uv","version":"0.11.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for mini_mne-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 fb7b50e32049c60a58bd990e5f228df960d017eb524590b31a8d21586608acac
MD5 7c0d14fa0035cc53df661d5106dd5975
BLAKE2b-256 bb89fd0ee6ab4c3657d835a56c45a30f85aa5bed8b94f86ad0e514c618fbbb18

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page