eelbrain.load.fiff.epochs(ds, tmin=-0.1, tmax=None, baseline=None, decim=1, mult=1, proj=False, data=None, reject=None, exclude='bads', info=None, name=None, raw=None, sensors=None, i_start='i_start', tstop=None, sysname=None)

Load epochs as NDVar.

ds : Dataset

Dataset containing a variable which defines epoch cues (i_start).

tmin : scalar

First sample to include in the epochs in seconds (Default is -0.1).

tmax : scalar

Last sample to include in the epochs in seconds (Default 0.6; use tstop instead to specify index exclusive of last sample).

baseline : (tmin, tmax)

Time interval for baseline correction. tmin and tmax in seconds, or None to use all the data (e.g., (None, 0) uses all the data from the beginning of the epoch up to t=0). baseline=None for no baseline correction (default).

decim : int

Downsample the data by this factor when importing. 1 means no downsampling. Note that this function does not low-pass filter the data. The data is downsampled by picking out every n-th sample (see Wikipedia).

mult : scalar

multiply all data by a constant.

proj : bool

mne.Epochs kwarg (subtract projections when loading data)

data : ‘eeg’ | ‘mag’ | ‘grad’

Which data channels data to include (default based on channels in data).

reject : None | scalar

Threshold for rejecting epochs (peak to peak). Requires a for of mne-python which implements the Epochs.model[‘index’] variable.

exclude : list of string | str

Channels to exclude (mne.pick_types() kwarg). If ‘bads’ (default), exclude channels in info[‘bads’]. If empty do not exclude any.

info : None | dict

Entries for the ndvar’s info dict.

name : str

name for the new NDVar.

raw : None | mne Raw

Raw file providing the data; if None,['raw'] is used.

sensors : None | Sensor

The default (None) reads the sensor locations from the fiff file. If the fiff file contains incorrect sensor locations, a different Sensor instance can be supplied through this kwarg.

i_start : str

name of the variable containing the index of the events.

tstop : scalar

Alternative to tmax: While tmax specifies the last samples to include, tstop can be used to specify the epoch time excluding the last time point (i.e., standard Python/Eelbrain indexing convention). For example, at 100 Hz the epoch with tmin=-0.1, tmax=0.4 will have 51 samples, while the epoch specified with tmin=-0.1, tstop=0.4 will have 50 samples.

sysname : str

Name of the sensor system to load sensor connectivity (e.g. ‘neuromag’, inferred automatically for KIT data converted with a recent version of MNE-Python).

epochs : NDVar

The epochs as NDVar object.