Back to the main page.

Bug 3205 - Expand ft_eletroderealign with the functionality of inward/outward shifting of electrode positions.

Status CLOSED FIXED
Reported 2016-11-07 13:10:00 +0100
Modified 2019-08-10 12:41:18 +0200
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Mac OS
Importance: P5 normal
Assigned to: Simon
URL:
Tags:
Depends on:
Blocks:
See also:

Simon - 2016-11-07 13:10:28 +0100

Expand ft_eletroderealign with the functionality of inward/outward shifting of electrode positions. Thinking of general function to do the shifting to maintain consistency with i.e. ft_prepare_sourcemodel where also inward/outwardshifts are done.


Simon - 2016-11-10 15:36:49 +0100

I tried an inward/outward shift of the /template/electrodes/standard_1020.elc with the following code: function [pos] = moveinward(pos, move) %This functions moves 'pos' inward according to their normals by 'move' %units propos = elproj(pos); tri = delaunay(propos); nor = normals(pos,tri); pos = pos-move*nor; end First we need to get rid of the 3rd dimension to assure that delaunay gives us an triangulation that is not closed at the bottom part of the electrode set. This prevents that the normals for the lower electrodes are biased by a flat triangulation of the lower part. However, this does not work for all electrodes of the standard_1020.elc as after projection their location isn't unique anymore.


Simon - 2016-11-17 12:44:30 +0100

Opened PR: https://github.com/fieldtrip/fieldtrip/pull/264


Robert Oostenveld - 2017-02-08 23:03:48 +0100

I have merged https://github.com/fieldtrip/fieldtrip/pull/264


Robert Oostenveld - 2019-08-10 12:35:05 +0200

This closes a whole series of bugs that have been resolved (either FIXED/WONTFIX/INVALID) for quite some time. If you disagree, please file a new issue on https://github.com/fieldtrip/fieldtrip/issues.


Robert Oostenveld - 2019-08-10 12:41:18 +0200

This closes a whole series of bugs that have been resolved (either FIXED/WONTFIX/INVALID) for quite some time. If you disagree, please file a new issue on https://github.com/fieldtrip/fieldtrip/issues.