Process_channel_addloc.m

Hi everyone,

I'm running into an issue adding eeg channel positions in process.

in the GUI, I do the following (image below) and it works great (0% rates between head points and head surface). i select the ant 64 waveguard

every step before and after positions also works great in 'process'. however, I cannot figure out why when I run add channel positions in process my data goes to 74% rate of >3mm distance between points and surfaces. here is my process script:

% Process: Add EEG positions
sFiles = bst_process('CallProcess', 'process_channel_addloc', sFiles, [], ...
    'channelfile', {'', ''}, ...
    'usedefault',  'ICBM152: ANT Waveguard 64', ...  % ICBM152: ANT Waveguard 64
    'fixunits',    0, ...
    'vox2ras',     1, ...
    'mrifile',     {RawFiles{3}, 'BST'}, ...
    'fiducials',   []);

in the GUI, i am selecting yes to transforming from mni to sensor space (i'm using individual mris). in process, i'm getting the same poor results with and without the vox2ras option.

Curious if anyone has any suggestions. Thank you!!

brian

Brian Kavanaugh, PsyD, ABPP Board Certified Pediatric Neuropsychologist, E. P. Bradley Hospital Assistant Professor, Warren Alpert Medical School of Brown University

Thanks for your response Raymundo! The issue still persists.

For example, when I run in process, I get the following. Looks like more than 61 head points?

When I then go ahead and do it in the GUI, I first get the following notification,

overwriting_process

but then the montage looks perfect

In this recent attempt, I did not use the MRI option for either the GUI or process.

Is there something in the process version of ANT 64 that I am not seeing?

Thanks Raymundo!

On our side, we are not able to reproduce the reported behaviour. It is working as it should.

Please post the results for both ways with: (i) hidden head points for the first plot, right-click on the black part of the figure > Channels > View head points; and (ii) both figures using the exact POV, right-click on the black part of the figure > Views > Left


As you are using a cap registered to a template anatomy, the options fixunits, vox2ras and mrifile do not have an impact. (As such my previous message was delete to avoid future confusion).

Yes, I am definitely messing something up that I'm not aware of.

Does it matter that I'm importing an EEGLAB file that already has channel locations? Also, should I be removing head points at some point, as it appears that sometimes I had 122 head points (as you saw in the prior post).

Here is what it looks like after I import the EEGLAB file

Here is after adding channel positions in the GUI

Here is after adding channel positions in the process tab

Thank you again Raymundo and I apologize for not yet being able to see how I'm messing up.

The locations of the electrodes seem to be the same in both plots (after adding locations with GUI and with Process). The difference is only for the head points.

Oh right! Can you explain what I'm doing wrong with the head points? And what actually are the head points?

It seems that if I remove the head points after importing eeg positions (cut-off of 1,000mm) i'm able to then able to project onto scalp and refine to 0% > 3mm (out of a new 61 head points). this seems to solve my issue, but does this conceptually sound reasonable?

You are not doing something wrong with the head points. More info below.
Head points are position on the scalp that are usually digitized (with devices Polhemus or Localite) once the EEG electrodes are placed on the scalp, so it is possible to have a better registration between the subject anatomy (MRI and head surface) and the position of the electrodes. See this links for additional information:

Do you know if head points (or electrode locations) were actually obtained for the EEG recordings?

It is reasonable approach if and only if the electrode positions were not digitized with a device to acquire their real positions. This seems the case with your data, as the head points are only the EEG positions, and these head points are created in Brainstorm when the EEGLab data is imported. As such, since they are not real head points (because the electrode positions were not digitized, but obtained from description of the cap) it is safe to remove them.

In fact, doing the Add EEG position with a default cap on a Default anatomy (e.g. ICBM152) in the GUI automatically removes the head points. There was bug in the process that skipped the removal of the head points after adding the EEG locations with a default cap on a default anatomy.
This is now fixed in commit: 8c494c5

Please update your Brainstorm instance and now you will see the same behaviour wither in the GUI or with the process.

Amazing, thank you Raymundo! this is great. and yes, our head points were just based on automated eeg positions, not actual head points we calculated. this is perfect, thank you again for helping me navigate!