Hi, I'm trying to go over a long list of talairach coordinates and to find their vertex indices. I did a bit of research and saw a previous question on the same topic: http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg12550.html
So I went on to write a tcl script in order to write the corresponding vertex indices to a file. But the problem is, the function selec_talairach_point gives 4 successive outputs, therefore I can't parse the vertex number because it gets overwritten. such as these:
% select_talairach_point 66.18 -14.56 39.06 surfer: vertex 68342: dist = 0.002702 % surfer: dmin=0.0027, vno=68342, x=43.6843, y=-11.1042, z=35.8562 % surfer: curv=0.000000, fs=0.000000 % surfer: val=0.000000, val2=0.000000 % surfer: amp=0.000000, angle=0.000000 deg (0.000000) % 0 (0 0 0)
My questions are: 1) is there an easier way of doing this besides writing a tcl script? 2) how can I access the function "selec_talairach_point" to modify it temporarily (so that it outputs ONLY vertex indices and not anything else) 3) is there a way to parse the output of this function in tcl?
Ali B. Arslan Graduate Student in Cognitive & Linguistic Sciences
Hi Ali
I've enabled a command in the latest dev build which does the following. This only prints the vertex without any other details.
% print_nearest_vertex_to_talairach_point -53.34 -7.81 -4.5 surfer: vertex 86131
Let me know your platform by an email off the list ( type freesurfer when you are in the environment and paste the last line) and I'll send you the latest version.
Regarding your questions:
1. tcl script is the best way to get relevant output for long list of coordinates 2. Unfortunately, most of the tcl commands invoke compiled C code, so you can't modify the "select_talairach_point" tcl function.
-Krish
On Apr 22, 2010, at 2:55 AM, Arslan, Ali wrote:
Hi, I'm trying to go over a long list of talairach coordinates and to find their vertex indices. I did a bit of research and saw a previous question on the same topic: http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg12550.html
So I went on to write a tcl script in order to write the corresponding vertex indices to a file. But the problem is, the function selec_talairach_point gives 4 successive outputs, therefore I can't parse the vertex number because it gets overwritten. such as these:
% select_talairach_point 66.18 -14.56 39.06 surfer: vertex 68342: dist = 0.002702 % surfer: dmin=0.0027, vno=68342, x=43.6843, y=-11.1042, z=35.8562 % surfer: curv=0.000000, fs=0.000000 % surfer: val=0.000000, val2=0.000000 % surfer: amp=0.000000, angle=0.000000 deg (0.000000) % 0 (0 0 0)
My questions are:
- is there an easier way of doing this besides writing a tcl script?
- how can I access the function "selec_talairach_point" to modify
it temporarily (so that it outputs ONLY vertex indices and not anything else) 3) is there a way to parse the output of this function in tcl?
Ali B. Arslan Graduate Student in Cognitive & Linguistic Sciences
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
could you make the name more verbose? Maybe something like:
compute_and_print_the_coordinates_of_the_vertex_closest_to_a_given_talairach_point?
good job Krish, Bruce
On Mon, 26 Apr 2010, Krish Subramaniam wrote:
Hi Ali
I've enabled a command in the latest dev build which does the following. This only prints the vertex without any other details.
% print_nearest_vertex_to_talairach_point -53.34 -7.81 -4.5 surfer: vertex 86131
Let me know your platform by an email off the list ( type freesurfer when you are in the environment and paste the last line) and I'll send you the latest version.
Regarding your questions:
- tcl script is the best way to get relevant output for long list of
coordinates 2. Unfortunately, most of the tcl commands invoke compiled C code, so you can't modify the "select_talairach_point" tcl function.
-Krish
On Apr 22, 2010, at 2:55 AM, Arslan, Ali wrote:
Hi, I'm trying to go over a long list of talairach coordinates and to find their vertex indices. I did a bit of research and saw a previous question on the same topic: http://www.mail-archive.com/freesurfer@nmr.mgh.harvard.edu/msg12550.html
So I went on to write a tcl script in order to write the corresponding vertex indices to a file. But the problem is, the function selec_talairach_point gives 4 successive outputs, therefore I can't parse the vertex number because it gets overwritten. such as these:
% select_talairach_point 66.18 -14.56 39.06 surfer: vertex 68342: dist = 0.002702 % surfer: dmin=0.0027, vno=68342, x=43.6843, y=-11.1042, z=35.8562 % surfer: curv=0.000000, fs=0.000000 % surfer: val=0.000000, val2=0.000000 % surfer: amp=0.000000, angle=0.000000 deg (0.000000) % 0 (0 0 0)
My questions are:
- is there an easier way of doing this besides writing a tcl script?
- how can I access the function "selec_talairach_point" to modify it
temporarily (so that it outputs ONLY vertex indices and not anything else) 3) is there a way to parse the output of this function in tcl?
Ali B. Arslan Graduate Student in Cognitive & Linguistic Sciences
Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
freesurfer@nmr.mgh.harvard.edu