Importing EEG sensor locations from txt file?

hello, i have electrode coordinates in MRI space, obtained similarly to the procedure used in this article:
http://www.sciencedirect.com/science/article/pii/S1053811911007828

along with anatomical T1 and the freesurfer output, so i have the head shape and cortical mesh. i managed to extract the locations of each electrode and now have 64 x,y,z coordinates in a text file (1 for each channel).
i just started using brainstorm, i see there's a tutorial on digitizing EEG sensor locations and head shape, but it seems to be more about the fast/isotrack hardware usage. i see at the end the points are all output to a txt file, however, so i'm wondering what is the best way to use my electrode and head shape information in brainstorm? should i try to create my own text file for the channel location coordinates, or is there a better way?
basically i'm wondering if there's a way i can incorporate all my structural information including head shape, cortical curvature, and EEG electrode placement into my source localization efforts.
thanks!
Russell

Hi Russell,

If you have the electrodes positions in a .txt file (one line = “Name X Y Z” for instance), you can load the electrodes positions as illustrated in this tutorial:
http://neuroimage.usc.edu/brainstorm/Tutorials/Epilepsy#Access_the_recordings

Brainstorm expects 3D positions in Brainstorm/CTF/SCS coordinates system:
http://neuroimage.usc.edu/brainstorm/CoordinateSystems

To get the electrodes converted to the correct coordinates system automatically, you just have to add the three referential points NAS/LPA/RPA in your text file.
This problem is similar to what has to be done for sEEG/ECoG electrodes. See the following threads:
http://neuroimage.usc.edu/forums/showthread.php?1049-visualizing-SEEG-electrodes-on-MRI
http://neuroimage.usc.edu/forums/showthread.php?1958-SEEG-electrodes-and-subject-s-anatomy-are-not-alligned
http://neuroimage.usc.edu/forums/showthread.php?2047-importing-coordinate-of-SEEG-elecs-from-Cartool

Cheers,
Francois

thanks for the reply. so if i understand correctly, all i have do is put 3 more lines in my txt file at the top or bottom with NAS/LPA/RPA labels and corresponding coordinates in the same space as my electrode coordinates? my electrode coordinates are not in any standardized space, however…just x,y,z values corresponding to voxel positions in the raw image…but as long as i have NAS/LPA/RPA in the same space, this shouldn’t be a problem?

also by the way i was wondering if there was an automatic way to locate NAS/LPA/RPA because hand-labeling doesn’t seem very robust. should be fairly easy to do with some simple feature detection, no?

Russell

Yes, you just have to add those three points.

There is no automatic NAS/LPA/RPA detection to my knowledge. These points are far from being easy to mark on many scans…
In your case, those points could be anywhere, you just have to pick the same sets of three points in the two programs.