Back to the main page.

Bug 3081 - ft_volumerealign error due to pnt/pos

Reported 2016-02-28 16:19:00 +0100
Modified 2016-06-14 16:14:52 +0200
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Mac OS
Importance: P5 normal
Assigned to: Robert Oostenveld
Depends on:
See also:

Robert Oostenveld - 2016-02-28 16:19:33 +0100

On 26 Feb 2016, at 14:06, Lau Møller Andersen wrote: Hi Robert I was using ft_volumerealign to align digitization data and MRI data, but kept getting this error: cfg = []; cfg.method = 'headshape'; cfg.headshape.headshape = headshape; [mri_realigned2] = ft_volumerealign(cfg, mri_realigned1); Reference to non-existent field 'pnt'. Error in ft_volumerealign (line 593) tmpcfg.template.elec.chanpos = shape.pnt; % ft_interactiverealign needs the field chanpos Shape is got from ft_read_headshape, which doesn't return a pnt-field. I was using fieldtrip-20160225. headshape = ft_read_headshape(fullpath, 'unit', 'mm') headshape = pos: [366x3 double] fid: [1x1 struct] label: {366x1 cell} coordsys: 'neuromag' unit: 'mm' I realized after some time that it works in 20151119, which does return a pnt-field headshape = ft_read_headshape(fullpath, 'unit', 'mm') pnt: [366x3 double] fid: [1x1 struct] label: {1x366 cell} coordsys: 'neuromag' unit: 'mm' I guess it's just the naming of the field (pos) that makes the difference. Best Lau

Robert Oostenveld - 2016-02-28 16:20:04 +0100

On 26 Feb 2016, at 14:07, Lau Møller Andersen wrote: the tutorial the subject refers to is:

Robert Oostenveld - 2016-02-28 17:32:33 +0100

(In reply to Robert Oostenveld from comment #1) I searched though the code and found some more "pnt"s that were not replaced by "pos". I made some changes and merged them in the master branch. See

Robert Oostenveld - 2016-06-14 16:14:52 +0200

Hereby I am closing multiple bugs that have been resolved for some time now. If you don't agree to the resolution, please reopen.