Skip to main content

MNEEpochData

Namespace: MNELIB  ·  Library: MNE Library

#include <mne/mne_epoch_data.h>

class MNELIB::MNEEpochData

Epoch data, which corresponds to an event.

Single epoch (trial slice) of sensor data with timing and rejection metadata.

src/examples/ex_mne_api/main.cpp
QFile rawFile(data + "/MEG/sample/sample_audvis_trunc_raw.fif");
const FiffRawData raw(rawFile);
FiffEvents events;
FiffEvents::detect_from_raw(raw, events); // rising edges on STI 014
// Epochs of event 1 from -100 to 300 ms, no rejection
MNEEpochDataList epochs = MNEEpochDataList::readEpochs(raw, events.events, -0.1f, 0.3f, 1, {});
const MNEEpochData& firstEpoch = *epochs.first();
FiffEvoked evoked = epochs.average(raw.info, raw.first_samp, raw.last_samp);

Public Methods​

MNEEpochData()​

Default constructor.


MNEEpochData(p_MNEEpochData)​

Copy constructor.

Parameters:

  • p_MNEEpochData : const MNEEpochData & MNE epoch data.

operator=(other)​

Copy assignment.

Every member has value semantics, so the compiler-generated member-wise assignment is correct. It is declared explicitly because declaring a copy constructor and/or a destructor deprecates the implicitly generated one.

Parameters:

Returns:


~MNEEpochData()​

Destroys the MNE epoch data.


applyBaselineCorrection(baseline)​

Applies baseline (mode=mean) correction to the evoked data.

Parameters:

  • baseline : const QPair< float, float > & time definition of the baseline in seconds [from, to].

pick_channels(sel)​

Reduces the data to the selected rows.

Parameters:

  • sel : const Eigen::RowVectorXi & The selected rows to keep.

isRejected(respectAutoReject)​

Returns whether this epoch should be excluded from averaging.

Parameters:

  • respectAutoReject : bool Whether automatic artifact rejection should be honored.

Returns:

  • bool — true when the epoch should be excluded.

Example​

Used in examples​

ex_clustered_inverse_mne_raw​

Example of the computation of a clustered inverse mne raw.

src/examples/ex_clustered_inverse_mne_raw/main.cpp, line 341
MNEEpochData* epoch = NULL;

ex_clustered_inverse_pwl_rap_music_raw​

Example of the computation of a raw clustered inverse Powell RAP-MUSIC.

src/examples/ex_clustered_inverse_pwl_rap_music_raw/main.cpp, line 350
MNEEpochData* epoch = NULL;

ex_clustered_inverse_rap_music_raw​

Example of the computation of a raw clustered inverse rap music.

src/examples/ex_clustered_inverse_rap_music_raw/main.cpp, line 347
MNEEpochData* epoch = NULL;

Also used in ex_dsp_preprocessing, ex_inverse_mne_raw, ex_mne_api.

Authors of this file​