mne.simulation.add_eog(raw, head_pos=None, interp='cos2', n_jobs=1, random_state=None, verbose=None)[source]

Parameters
rawinstance of Raw

The raw instance to modify.

Name of the position estimates file. Should be in the format of the files produced by MaxFilter. If dict, keys should be the time points and entries should be 4x4 dev_head_t matrices. If None, the original head position (from info['dev_head_t']) will be used. If tuple, should have the same format as data returned by head_pos_to_trans_rot_t. If array, should be of the form returned by mne.chpi.read_head_pos().

interpstr

Either ‘hann’, ‘cos2’ (default), ‘linear’, or ‘zero’, the type of forward-solution interpolation to use between forward solutions at different head positions.

n_jobsint

The number of jobs to run in parallel (default 1). Requires the joblib package.

random_stateNone | int | instance of RandomState

If random_state is an int, it will be used as a seed for RandomState. If None, the seed will be obtained from the operating system (see RandomState for details). Default is None. The random generator state used for blink, ECG, and sensor noise randomization.

verbose

If not None, override default verbose level (see mne.verbose() and Logging documentation for more).

Returns
rawinstance of Raw

The instance, modified in place.

Notes

The blink artifacts are generated by:

1. Random activation times are drawn from an inhomogeneous poisson process whose blink rate oscillates between 4.5 blinks/minute and 17 blinks/minute based on the low (reading) and high (resting) blink rates from [1].

2. The activation kernel is a 250 ms Hanning window.

3. Two activated dipoles are located in the z=0 plane (in head coordinates) at ±30 degrees away from the y axis (nasion).

4. Activations affect MEG and EEG channels.

The scale-factor of the activation function was chosen based on visual inspection to yield amplitudes generally consistent with those seen in experimental data. Noisy versions of the activation will be stored in the first EOG channel in the raw instance, if it exists.

References

1

Bentivoglio et al. “Analysis of blink rate patterns in normal subjects” Movement Disorders, 1997 Nov;12(6):1028-34.