Re: [Freesurfer] tksurfer-sess frame time course question

2018-09-28 Thread ylab
External Email - Use Caution

Dear Doug,

Thank you very much for your response.

>> (1) why did I get Frame (0-8) for my data that should have 12 frames?
> When you use -rmprestim, it subtracts the mean of the prestim baseline
> AND removes the prestim time points (-4 -2 and 0) so you only end up
> with 9 frames.

I see. This makes perfect sense.

>> (2) how can I visualize contrasts created with -setwdelay?
> Your visualization command is correct. I don’t understand why you are
> seeing the same image for each frame. Can you load them separately and
> see if they are different?

I tried to load them separately, but still got the same images.
tksurfer-sess -df sessdirfile -s YY03 -analysis YY.sm5.lh -contrast w1_all_null 
-map sig
tksurfer-sess -df sessdirfile -s YY03 -analysis YY.sm5.lh -contrast w5_all_null 
-map sig

I also loaded /YY03/bold/YY.sm5.lh/w1_all_null/sig.nii.gz, and 
/YY03/bold/YY.sm5.lh/w5_all_null/sig.nii.gz, using GUI on FreeView, still got 
the same images.

Then, I created new contrasts without -rmprestim
mkcontrast-sess -analysis YY.sm5.lh -contrast w1b_all_null -a 1 -a 2 -a 3 -a 4 
-a 5 -a 6 -a 7 -a 8 -c 0 -setwdelay [1 0 0 0 0 0 0 0 0 0 0 0]

mkcontrast-sess -analysis YY.sm5.lh -contrast w5b_all_null -a 1 -a 2 -a 3 -a 4 
-a 5 -a 6 -a 7 -a 8 -c 0 -setwdelay [0 0 0 0 1 0 0 0 0 0 0 0]

Without -rmprestim, I was able to see different maps.
So it looks like when I used -rmprestim, I failed to create different 
sig.nii.gz files for the different contrasts.

Now, I can continue my analyses without -rmprestim. But I have one follow up 
question.

(3) when I used -rmprestim with mkcontrast-sess, is it correct to assume that 
the statistical results produced by selxavg3-sess were based on the data with 
the prestimulus activation subtracted?
With -rmprestim, sig.nii.gz had 9 frames. I am confused because, the data I 
visualized with freesurfer version 5 by clicking the activated areas had 12 
frames. I am wondering where did the first three frames came from in those 
plots.

Thank you in advance.
Shogo___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Re recon -all

2018-09-28 Thread Miguel Ángel Rivas Fernández
External Email - Use Caution

Hi Bruce,

What an absurd mistake, sorry.

However, I ran the command and I got the following error:

pcpb3846:~ lab1-rmn$ recon-all -autorecon2-cp -autorecon3 -subjid 5054
INFO: FreeSurfer build stamps do not match
Subject Stamp: freesurfer-Darwin-lion-stable-pub-v5.3.0
Current Stamp: freesurfer-Darwin-OSX-stable-pub-v6.0.0-2beb96c
INFO: SUBJECTS_DIR is /Applications/freesurfer/subjects
Actual FREESURFER_HOME /Applications/freesurfer
-rwxr-xrwx  1 root  wheel  508088 Sep 28 19:52
/Applications/freesurfer/subjects/5054/scripts/recon-all.log
Darwin pcpb3846.inv.usc.es 15.6.0 Darwin Kernel Version 15.6.0: Thu Jun 21
20:07:40 PDT 2018; root:xnu-3248.73.11~1/RELEASE_X86_64 x86_64
#
#@# Intensity Normalization2 Fri Sep 28 23:13:36 CEST 2018
/Applications/freesurfer/subjects/5054/mri
\n mri_normalize -f /Applications/freesurfer/subjects/5054/tmp/control.dat
-mprage -aseg aseg.presurf.mgz -mask brainmask.mgz norm.mgz brain.mgz \n
mghRead(/Applications/freesurfer/subjects/5054/mri/aseg.presurf.mgz, -1):
could not open file
using control points from file
/Applications/freesurfer/subjects/5054/tmp/control.dat...
assuming input volume is MGH (Van der Kouwe) MP-RAGE
using segmentation for initial intensity normalization
using MR volume brainmask.mgz to mask input volume...
reading from norm.mgz...
Reading aseg aseg.presurf.mgz
mri_normalize: could not read aseg from file aseg.presurf.mgz
Darwin pcpb3846.inv.usc.es 15.6.0 Darwin Kernel Version 15.6.0: Thu Jun 21
20:07:40 PDT 2018; root:xnu-3248.73.11~1/RELEASE_X86_64 x86_64

recon-all -s 5054 exited with ERRORS at Fri Sep 28 23:13:38 CEST 2018

For more details, see the log file
/Applications/freesurfer/subjects/5054/scripts/recon-all.log
To report a problem, see
http://surfer.nmr.mgh.harvard.edu/fswiki/BugReporting


Why?


Thanks for your help,

Best,

El vie., 28 sept. 2018 a las 19:38, Bruce Fischl (<
fis...@nmr.mgh.harvard.edu>) escribió:

> Looks like you have an incorrect space after the word recon
>
> On Sep 28, 2018, at 1:35 PM, Miguel Ángel Rivas Fernández <
> miguelrivasf...@gmail.com> wrote:
>
> External Email - Use Caution
>
>
> Hi Freesurfer devs,
>
>
> I tried to re run the recon -all after put some control points in the
> brainmask and I get the following error:
>
>
> pcpb3846:~ lab1-rmn$ recon -all -autorecon2-cp -autorecon3 -4025 cp_before
>
> -bash: recon: command not found
>
>
>
>
> What could be the problem? The Freesurfer version that I am using at this
> moment is freesurfer-Darwin-OSX-stable-pub-v6.0.0-2beb96c
>
>
>
>
> Thanks in advance,
>
>
> Best,
> --
> *Miguel Ángel Rivas Fernández*
>
> ___
> Freesurfer mailing list
> Freesurfer@nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
>
> ___
> Freesurfer mailing list
> Freesurfer@nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer



-- 
*Miguel Ángel Rivas Fernández*
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Re recon -all

2018-09-28 Thread Bruce Fischl
Looks like you have an incorrect space after the word recon 

> On Sep 28, 2018, at 1:35 PM, Miguel Ángel Rivas Fernández 
>  wrote:
> 
> External Email - Use Caution
> 
> 
> Hi Freesurfer devs, 
> 
> 
> I tried to re run the recon -all after put some control points in the 
> brainmask and I get the following error:
> 
> 
> pcpb3846:~ lab1-rmn$ recon -all -autorecon2-cp -autorecon3 -4025 cp_before
> -bash: recon: command not found
> 
> 
> 
> What could be the problem? The Freesurfer version that I am using at this 
> moment is freesurfer-Darwin-OSX-stable-pub-v6.0.0-2beb96c
> 
> 
> 
> Thanks in advance, 
> 
> 
> Best, 
> -- 
> Miguel Ángel Rivas Fernández
> ___
> Freesurfer mailing list
> Freesurfer@nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

[Freesurfer] Re recon -all

2018-09-28 Thread Miguel Ángel Rivas Fernández
External Email - Use Caution

Hi Freesurfer devs,


I tried to re run the recon -all after put some control points in the
brainmask and I get the following error:


pcpb3846:~ lab1-rmn$ recon -all -autorecon2-cp -autorecon3 -4025 cp_before

-bash: recon: command not found




What could be the problem? The Freesurfer version that I am using at this
moment is freesurfer-Darwin-OSX-stable-pub-v6.0.0-2beb96c




Thanks in advance,


Best,
-- 
*Miguel Ángel Rivas Fernández*
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Clarification about .annot file format

2018-09-28 Thread Christopher Markiewicz
External Email - Use Caution

Doug,


I think that's the only one.


Chris


From: freesurfer-boun...@nmr.mgh.harvard.edu 
 on behalf of Greve, Douglas N.,Ph.D. 

Sent: Friday, September 28, 2018 1:09:50 PM
To: freesurfer@nmr.mgh.harvard.edu
Subject: Re: [Freesurfer] Clarification about .annot file format

Is this the offending line? or is there more?
value = (A * 2563) + (B * 2562) + (G * 256) + (R)


On 9/28/18 1:03 PM, Christopher Markiewicz wrote:

External Email - Use Caution

Hi Doug,


The relevant wiki page is: 
https://surfer.nmr.mgh.harvard.edu/fswiki/LabelsClutsAnnotationFiles#Annotation


Chris


From: 
freesurfer-boun...@nmr.mgh.harvard.edu
 

 on behalf of Greve, Douglas N.,Ph.D. 

Sent: Friday, September 28, 2018 12:47:36 PM
To: freesurfer@nmr.mgh.harvard.edu
Subject: Re: [Freesurfer] Clarification about .annot file format

Thanks Chris, can you point us to the offending wiki page?
doug

On 9/28/18 12:44 PM, Christopher Markiewicz wrote:

External Email - Use Caution

Hi all,


I believe I've gotten to the bottom of this, and the problem is incorrect 
documentation, both in the read/write_annotation.m files and in the wiki.


Taking the FreeSurfer C source as the de facto specification, we can refer to 
the colortab.c file. Here, the labels are not constructed or decoded using the 
transparency (255 - alpha) information at all, but are simply (R + G << 8 + B 
<< 16).


For more complete discussion, see:


https://github.com/nipy/nibabel/issues/649#issuecomment-424755969


I think the most parsimonious resolution of this confusion is simply to update 
the documentation on the wiki page (I cannot; someone with permissions will 
need to), and to patch the MATLAB code to build its labels from RGB values 
alone. I will submit a patch to the GitHub branch.

Please let me know if I've gotten something wrong.

Best,
Chris Markiewicz


From: 
freesurfer-boun...@nmr.mgh.harvard.edu
 

 on behalf of paul mccarthy 

Sent: Thursday, September 20, 2018 11:39:53 AM
To: freesurfer@nmr.mgh.harvard.edu
Subject: [Freesurfer] Clarification about .annot file format


External Email - Use Caution

Howdy,

There is a discussion regarding the .annot file format over at the nibabel 
github repository, regarding the interpretation of the flag/alpha value:

https://github.com/nipy/nibabel/issues/649

If one wishes to create an .annot file with colours that have a transparency 
value, how should it be stored in the file? By piecing together the information 
from the freesurfer code [1,2], and Graham Wideman's helpful notes [3], I came 
to the conclusion that alpha values should be stored as 1-the actual value. But 
it would be great to get some clarification on this from somebody who knows 
more than me

Thanks very much,

Paul McCarthy

[1] https://github.com/freesurfer/freesurfer/blob/dev/matlab/read_annotation.m
[2] https://github.com/freesurfer/freesurfer/blob/dev/matlab/write_annotation.m
[3] 
https://surfer.nmr.mgh.harvard.edu/fswiki/LabelsClutsAnnotationFiles#Annotation



___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer




___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Clarification about .annot file format

2018-09-28 Thread Greve, Douglas N.,Ph.D.
Is this the offending line? or is there more?
value = (A * 2563) + (B * 2562) + (G * 256) + (R)


On 9/28/18 1:03 PM, Christopher Markiewicz wrote:

External Email - Use Caution

Hi Doug,


The relevant wiki page is: 
https://surfer.nmr.mgh.harvard.edu/fswiki/LabelsClutsAnnotationFiles#Annotation


Chris


From: 
freesurfer-boun...@nmr.mgh.harvard.edu
 

 on behalf of Greve, Douglas N.,Ph.D. 

Sent: Friday, September 28, 2018 12:47:36 PM
To: freesurfer@nmr.mgh.harvard.edu
Subject: Re: [Freesurfer] Clarification about .annot file format

Thanks Chris, can you point us to the offending wiki page?
doug

On 9/28/18 12:44 PM, Christopher Markiewicz wrote:

External Email - Use Caution

Hi all,


I believe I've gotten to the bottom of this, and the problem is incorrect 
documentation, both in the read/write_annotation.m files and in the wiki.


Taking the FreeSurfer C source as the de facto specification, we can refer to 
the colortab.c file. Here, the labels are not constructed or decoded using the 
transparency (255 - alpha) information at all, but are simply (R + G << 8 + B 
<< 16).


For more complete discussion, see:


https://github.com/nipy/nibabel/issues/649#issuecomment-424755969


I think the most parsimonious resolution of this confusion is simply to update 
the documentation on the wiki page (I cannot; someone with permissions will 
need to), and to patch the MATLAB code to build its labels from RGB values 
alone. I will submit a patch to the GitHub branch.

Please let me know if I've gotten something wrong.

Best,
Chris Markiewicz


From: 
freesurfer-boun...@nmr.mgh.harvard.edu
 

 on behalf of paul mccarthy 

Sent: Thursday, September 20, 2018 11:39:53 AM
To: freesurfer@nmr.mgh.harvard.edu
Subject: [Freesurfer] Clarification about .annot file format


External Email - Use Caution

Howdy,

There is a discussion regarding the .annot file format over at the nibabel 
github repository, regarding the interpretation of the flag/alpha value:

https://github.com/nipy/nibabel/issues/649

If one wishes to create an .annot file with colours that have a transparency 
value, how should it be stored in the file? By piecing together the information 
from the freesurfer code [1,2], and Graham Wideman's helpful notes [3], I came 
to the conclusion that alpha values should be stored as 1-the actual value. But 
it would be great to get some clarification on this from somebody who knows 
more than me

Thanks very much,

Paul McCarthy

[1] https://github.com/freesurfer/freesurfer/blob/dev/matlab/read_annotation.m
[2] https://github.com/freesurfer/freesurfer/blob/dev/matlab/write_annotation.m
[3] 
https://surfer.nmr.mgh.harvard.edu/fswiki/LabelsClutsAnnotationFiles#Annotation



___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer




___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Clarification about .annot file format

2018-09-28 Thread Christopher Markiewicz
External Email - Use Caution

Hi Doug,


The relevant wiki page is: 
https://surfer.nmr.mgh.harvard.edu/fswiki/LabelsClutsAnnotationFiles#Annotation


Chris


From: freesurfer-boun...@nmr.mgh.harvard.edu 
 on behalf of Greve, Douglas N.,Ph.D. 

Sent: Friday, September 28, 2018 12:47:36 PM
To: freesurfer@nmr.mgh.harvard.edu
Subject: Re: [Freesurfer] Clarification about .annot file format

Thanks Chris, can you point us to the offending wiki page?
doug

On 9/28/18 12:44 PM, Christopher Markiewicz wrote:

External Email - Use Caution

Hi all,


I believe I've gotten to the bottom of this, and the problem is incorrect 
documentation, both in the read/write_annotation.m files and in the wiki.


Taking the FreeSurfer C source as the de facto specification, we can refer to 
the colortab.c file. Here, the labels are not constructed or decoded using the 
transparency (255 - alpha) information at all, but are simply (R + G << 8 + B 
<< 16).


For more complete discussion, see:


https://github.com/nipy/nibabel/issues/649#issuecomment-424755969


I think the most parsimonious resolution of this confusion is simply to update 
the documentation on the wiki page (I cannot; someone with permissions will 
need to), and to patch the MATLAB code to build its labels from RGB values 
alone. I will submit a patch to the GitHub branch.

Please let me know if I've gotten something wrong.

Best,
Chris Markiewicz


From: 
freesurfer-boun...@nmr.mgh.harvard.edu
 

 on behalf of paul mccarthy 

Sent: Thursday, September 20, 2018 11:39:53 AM
To: freesurfer@nmr.mgh.harvard.edu
Subject: [Freesurfer] Clarification about .annot file format


External Email - Use Caution

Howdy,

There is a discussion regarding the .annot file format over at the nibabel 
github repository, regarding the interpretation of the flag/alpha value:

https://github.com/nipy/nibabel/issues/649

If one wishes to create an .annot file with colours that have a transparency 
value, how should it be stored in the file? By piecing together the information 
from the freesurfer code [1,2], and Graham Wideman's helpful notes [3], I came 
to the conclusion that alpha values should be stored as 1-the actual value. But 
it would be great to get some clarification on this from somebody who knows 
more than me

Thanks very much,

Paul McCarthy

[1] https://github.com/freesurfer/freesurfer/blob/dev/matlab/read_annotation.m
[2] https://github.com/freesurfer/freesurfer/blob/dev/matlab/write_annotation.m
[3] 
https://surfer.nmr.mgh.harvard.edu/fswiki/LabelsClutsAnnotationFiles#Annotation



___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Clarification about .annot file format

2018-09-28 Thread Greve, Douglas N.,Ph.D.
Thanks Chris, can you point us to the offending wiki page?
doug

On 9/28/18 12:44 PM, Christopher Markiewicz wrote:

External Email - Use Caution

Hi all,


I believe I've gotten to the bottom of this, and the problem is incorrect 
documentation, both in the read/write_annotation.m files and in the wiki.


Taking the FreeSurfer C source as the de facto specification, we can refer to 
the colortab.c file. Here, the labels are not constructed or decoded using the 
transparency (255 - alpha) information at all, but are simply (R + G << 8 + B 
<< 16).


For more complete discussion, see:


https://github.com/nipy/nibabel/issues/649#issuecomment-424755969


I think the most parsimonious resolution of this confusion is simply to update 
the documentation on the wiki page (I cannot; someone with permissions will 
need to), and to patch the MATLAB code to build its labels from RGB values 
alone. I will submit a patch to the GitHub branch.

Please let me know if I've gotten something wrong.

Best,
Chris Markiewicz


From: 
freesurfer-boun...@nmr.mgh.harvard.edu
 

 on behalf of paul mccarthy 

Sent: Thursday, September 20, 2018 11:39:53 AM
To: freesurfer@nmr.mgh.harvard.edu
Subject: [Freesurfer] Clarification about .annot file format


External Email - Use Caution

Howdy,

There is a discussion regarding the .annot file format over at the nibabel 
github repository, regarding the interpretation of the flag/alpha value:

https://github.com/nipy/nibabel/issues/649

If one wishes to create an .annot file with colours that have a transparency 
value, how should it be stored in the file? By piecing together the information 
from the freesurfer code [1,2], and Graham Wideman's helpful notes [3], I came 
to the conclusion that alpha values should be stored as 1-the actual value. But 
it would be great to get some clarification on this from somebody who knows 
more than me

Thanks very much,

Paul McCarthy

[1] https://github.com/freesurfer/freesurfer/blob/dev/matlab/read_annotation.m
[2] https://github.com/freesurfer/freesurfer/blob/dev/matlab/write_annotation.m
[3] 
https://surfer.nmr.mgh.harvard.edu/fswiki/LabelsClutsAnnotationFiles#Annotation



___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer

Re: [Freesurfer] Clarification about .annot file format

2018-09-28 Thread Christopher Markiewicz
External Email - Use Caution

Hi all,


I believe I've gotten to the bottom of this, and the problem is incorrect 
documentation, both in the read/write_annotation.m files and in the wiki.


Taking the FreeSurfer C source as the de facto specification, we can refer to 
the colortab.c file. Here, the labels are not constructed or decoded using the 
transparency (255 - alpha) information at all, but are simply (R + G << 8 + B 
<< 16).


For more complete discussion, see:


https://github.com/nipy/nibabel/issues/649#issuecomment-424755969


I think the most parsimonious resolution of this confusion is simply to update 
the documentation on the wiki page (I cannot; someone with permissions will 
need to), and to patch the MATLAB code to build its labels from RGB values 
alone. I will submit a patch to the GitHub branch.

Please let me know if I've gotten something wrong.

Best,
Chris Markiewicz


From: freesurfer-boun...@nmr.mgh.harvard.edu 
 on behalf of paul mccarthy 

Sent: Thursday, September 20, 2018 11:39:53 AM
To: freesurfer@nmr.mgh.harvard.edu
Subject: [Freesurfer] Clarification about .annot file format


External Email - Use Caution

Howdy,

There is a discussion regarding the .annot file format over at the nibabel 
github repository, regarding the interpretation of the flag/alpha value:

https://github.com/nipy/nibabel/issues/649

If one wishes to create an .annot file with colours that have a transparency 
value, how should it be stored in the file? By piecing together the information 
from the freesurfer code [1,2], and Graham Wideman's helpful notes [3], I came 
to the conclusion that alpha values should be stored as 1-the actual value. But 
it would be great to get some clarification on this from somebody who knows 
more than me

Thanks very much,

Paul McCarthy

[1] https://github.com/freesurfer/freesurfer/blob/dev/matlab/read_annotation.m
[2] https://github.com/freesurfer/freesurfer/blob/dev/matlab/write_annotation.m
[3] 
https://surfer.nmr.mgh.harvard.edu/fswiki/LabelsClutsAnnotationFiles#Annotation
___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer