Laplacian or local average reference in mne

Dear Colleagues,

I’m configuring a GUI using tkinter. Is that possible to configure laplacian (local average reference) in mne EEG. It is good dealing at focal epilepsy or other focal lesions, for instance, focal vascular, cortical focal displasias, etc. It really “cleans” garbage from signal.

If not:

I was wandering if is possible, for example, to create a ‘lar’ virtual reference for, lets say, F7, by doing—> (Fp1+F3+T3) /3, and keeping channels Fp1 F3 T3 still plotting. Should I use instead —> (Fp1+F3 +F7+T3) / 3, to get a reference for F7. I could do the same for
all channels. By the way would it be correct, could I call it lar reference?

Or,
Do you know any algorithm tha I could adapt to mne EEg to build Lar

Among other fonts I’ve read 'The Surface Laplacian Technique in EEG: Theory and Methods(1)
but couldn’t figure it out.

(1) https://arxiv.org/pdf/1406.0458.pdf

best,

Paulo Kanda
University of Sao Paulo
Brazil

MNE currently only supports average or single/multi-electrode references (mne.set_eeg_reference()) and bipolar references (mne.set_bipolar_reference()). Local average reference (aka Laplacian) would need to take channel neighborhoods into account, including the desired number of neighboring electrodes.

Any chance to have it in the future?

best
Kanda

I don’t think that anyone is currently working on it – maybe you can try and make a pull request?

1 Like

I’d like to try, but Im a physician not a mathematician. Laplacian reference is importan to clinicians. It helps to focus localized generators as epileptic foci. If anyone know where can I gather info to build it, would be of help . I work with 20 electrodes, for instance, reference for T3 is just the mean of (F7+ C3+ T5) microvolts/3 ? I cant believe it could be so ease. ‘‘what’s the catch’’ in buinding of this so important reference? best. PKanda

Coming up with something sufficiently generic to integrate in MNE-Python is probably a decent amount of work. However, you could relatively quickly hack something that works just for your use case. It is probably easiest if you work directly with the NumPy array holding the EEG data (raw.get_data()) . That way, you could create a new RawArray from scratch by computing the Laplace derivations for each channel manually, exactly as you suggested.

I’ve added this as a feature request to our GitHub repository: support Laplacian referencing for EEG · Issue #9659 · mne-tools/mne-python · GitHub

@PauloKanda if you have any additional info to add (additional papers showing the benefits of local average referencing, any parameters that you will need to be able to control case-by-case, etc) please add them there.

3 Likes

Just for the completeness of this thread, I add a summary of the GitHub issue linked above (now closed).
The terms “Laplacian” and “Current Source Density” (CSD) are often used interchangeably in the EEG literature (see for example: https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4610715/).
CSD is available in mne, see this example to see how it can be done.

1 Like

Dear Mr MMagnusk

Very interesting and helpful

thanks again

Paulo Kanda