Back to the main page.

Bug 880 - layout file info on wiki does not specify reference frame for X- and Y-coordinates

Status CLOSED FIXED
Reported 2011-08-17 16:19:00 +0200
Modified 2019-08-10 12:03:20 +0200
Product: FieldTrip
Component: documentation
Version: unspecified
Hardware: PC
Operating System: Windows
Importance: P1 normal
Assigned to: Arjen Stolk
URL: http://fieldtrip.fcdonders.nl/faq/what_is_the_format_of_the_layout_file_which_is_used_for_plotting
Tags:
Depends on:
Blocks:
See also:

Eelke Spaak - 2011-08-17 16:19:33 +0200

See http://fieldtrip.fcdonders.nl/faq/what_is_the_format_of_the_layout_file_which_is_used_for_plotting It is mentioned that "The 2nd and 3rd are the X-position and Y-position", but not which coordinate system they use. It's not the standard Matlab axes-system ( (0,0) bottom left corner; (1,1) top right corner), as I found out by trial-and-error, but which is it? My guess is center = (0,0) and anything fitting within the unit circle is valid, but I don't know and someone who does should document it :) Also, while this person is at it, the width/height units should be documented.


Robert Oostenveld - 2011-08-17 18:28:06 +0200

please have a look at it with ft_plot_layout (and look into that functions code)


Boris Reuderink - 2011-11-17 10:46:41 +0100

Changed the status of bugs without a specific owner to UNCONFIRMED. I'll try to replicate these bugs (potentially involving the submitter), and change confirmed bugs to NEW. Boris


Boris Reuderink - 2012-01-11 17:26:53 +0100

Robert (on the computer of Boris): there is no specific reference frame. How do you suggest that this should be documented?


Eelke Spaak - 2012-02-08 14:03:03 +0100

Arjen, once the layout stuff is done, the layout documentation on the wiki needs to be changed anyway, so I'm assigning this to you :)


Arjen Stolk - 2012-07-25 10:47:19 +0200

Thx. ;) This will be thrown on the huge pile of layout related bugs. Most likely these will all instantly be dealt with with the transover from .lay to .mat files.


Arjen Stolk - 2013-01-15 20:48:29 +0100

Most of the desired information regarding the layout structures (.lay and .mat files) are documented here: http://fieldtrip.fcdonders.nl/template/layout


Arjen Stolk - 2013-01-15 20:48:59 +0100

see above/below


Robert Oostenveld - 2013-01-16 12:51:55 +0100

(In reply to comment #7) Open question: what is the coordinate system of the numbers of the layout file? Possible answer: they can be expressed in an arbitrary coordinate system. Once read in, they will be shifted and scaled such that .... [here come details that require a look in the ft_prepare_layout code]. After shifting and scaling, a circle representing the head with nose and ears will be added. This circle has a diameter of ... [again look at code]. This should be added to the faq.


Arjen Stolk - 2013-01-16 15:41:25 +0100

Agreed. The 2-D positions of the electrodes can be expressed in an arbitrary coordinate system. Once read in, they will be shifted and scaled such that they fit within a prespecified x- and y-range ([-0.45 0.45] a.u.). After shifting and scaling, a circle representing the head with nose and ears will be added. This circle has a center (0,0) and radius 0.5 (a.u.). the details can be found around line 600 of ft_prepare_layout and The width and height are used for the subplot that will be made in ft_multiplotER and ft_multiplotTFR. The width and height represent 80 and 60% of the smallest 2D electrode position distance respectively.


Robert Oostenveld - 2013-01-16 16:19:09 +0100

(In reply to comment #9) please refer to the layout in terms of "channels", not in terms of :"electrodes". In the case of a bipolar channel, there are two electrodes but still a single graph has to be shown.


Arjen Stolk - 2013-01-16 17:49:42 +0100

Correct, thanks.


Robert Oostenveld - 2019-08-10 12:03:20 +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 describing the issue on https://github.com/fieldtrip/fieldtrip/issues.