[FieldTrip] Rotating sensors using ft_transform_sens

Pomper, Ulrich u.pomper at ucl.ac.uk
Sun May 14 13:36:13 CEST 2017


Dear Julian,


Thanks a lot for your help!

>From looking into the function as you suggested, it seems the transformation matrix is actually 4 dimensional, with one extra dimension for scaling. I managed to rotate the sensors but they are still quite far away from the headvolume.

I tried using ft_sensorrealign (MEG equivalent of ft_electroderealign) but am getting an errormessage


Undefined function or variable "pnt".

Error in channelposition (line 327)
pnt = pnt(sel2, :);



which I haven't had time to follow up yet. I will post more once I have looked into it.

Anyway, thanks again for the help so far.


Cheers,

Ulrich



________________________________
From: fieldtrip-bounces at science.ru.nl <fieldtrip-bounces at science.ru.nl> on behalf of Julian Keil <julian.keil at gmail.com>
Sent: 12 May 2017 08:44
To: FieldTrip discussion list
Subject: Re: [FieldTrip] Rotating sensors using ft_transform_sens

Dear Ulrich,

could you use ft_electroderealign with the interactive-option instead?
Here you have an graphic interface that lets you rotate the electrodes in all directions to match your headshape.
ft_transform_sens is used in this function, so the output should be the same.
Moreover, if you check the code of ft_electroderealign, it can give you a hint to what the transform-matrix should look like: I think it should be a 3x3-matrix with scale, transform and rotate xyz-vectors.

I hope this helps,

Julian


Am 11.05.2017 um 19:21 schrieb Pomper, Ulrich:

Dear Listmembers,

Could someone please explain how to use ft_transform_sens in order to rotate sensors around a given axis?
For example, how would the input variable 'transform' need to look like in order to perform a 90 degree rotation around the z-axis?

Many thanks,
Ulrich

_______________________________________________
fieldtrip mailing list
fieldtrip at donders.ru.nl<mailto:fieldtrip at donders.ru.nl>
https://mailman.science.ru.nl/mailman/listinfo/fieldtrip

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20170514/c4c91a75/attachment-0002.html>


More information about the fieldtrip mailing list