Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
development:minimum_norm_estimate_new [2013/10/05 18:50]
131.174.45.163 [Source model]
development:minimum_norm_estimate_new [2017/08/17 11:21] (current)
Line 44: Line 44:
 ===== Processing of anatomical data ===== ===== Processing of anatomical data =====
 \\ \\
-The following will use the anatomical MRI belonging to Subject01. The file can be obtained from [[ftp://​ftp.fcdonders.nl/​pub/​fieldtrip/​tutorial/​Subject01.zip]].+The following will use the anatomical MRI belonging to Subject01. The file can be obtained from [[ftp://​ftp.fieldtriptoolbox.org/​pub/​fieldtrip/​tutorial/​Subject01.zip]].
 The functions described in this part of the tutorial are using toolboxes that are under the fieldtrip/​external folder. You do not have to add these toolboxes yourself, but it is important that you set up your matlab path properly. You can read about how to set up your matlab path [[faq:​should_i_add_fieldtrip_with_all_subdirectories_to_my_matlab_path|here]]. ​ The functions described in this part of the tutorial are using toolboxes that are under the fieldtrip/​external folder. You do not have to add these toolboxes yourself, but it is important that you set up your matlab path properly. You can read about how to set up your matlab path [[faq:​should_i_add_fieldtrip_with_all_subdirectories_to_my_matlab_path|here]]. ​
  
Line 200: Line 200:
  
 Here is a [[http://​surfer.nmr.mgh.harvard.edu/​fswiki/​ReconAllDevTable|link]] to the different processing steps. Although the Freesurfer procedure can be invoked using only a few Freesurfer commands, below we will describe the (sub)commands that will achieve the same. These commands sequentially generate a series of files (volumetric,​ surface and transformation matrices). Each of the output files serves as input to the sequential analysis steps. A table of file dependencies can be found [[http://​surfer.nmr.mgh.harvard.edu/​fswiki/​ReconAllFilesVsSteps|here]].\\ Here is a [[http://​surfer.nmr.mgh.harvard.edu/​fswiki/​ReconAllDevTable|link]] to the different processing steps. Although the Freesurfer procedure can be invoked using only a few Freesurfer commands, below we will describe the (sub)commands that will achieve the same. These commands sequentially generate a series of files (volumetric,​ surface and transformation matrices). Each of the output files serves as input to the sequential analysis steps. A table of file dependencies can be found [[http://​surfer.nmr.mgh.harvard.edu/​fswiki/​ReconAllFilesVsSteps|here]].\\
-There are a few analysis steps in Freesurfer, which are not guaranteed to give a nice result, and require some user interaction to get it right. Moreover, Freesurfer can be quite picky with respect to the exact format of the MRI-volumes. One step which, in our experience is notorious for not being very robust is automatic skull-stripping. Therefore, we advocate a hybrid approach that uses SPM for an initial segmentation of the anatomical MRI during the preprocessing. With this segmentation,​ we created a brainmask that provides a robustly skull-stripped image, which is a prerequisite for a correct segmentation in Freesurfer. Although this approach may seem a bit convoluted (you may rightfully ask why we need to redo the segmentation in Freesurfer if we already did it in SPM), the interdependencies between different files generated along the Freesurfer pipeline make tapping into this pipeline at a random point quite complicated. For this reason a large part of the volumetric processing in Freesurfer needs to be done as well.+There are a few analysis steps in Freesurfer, which are not guaranteed to give a nice result, and require some user interaction to get it right. Moreover, Freesurfer can be quite picky with respect to the exact format of the MRI-volumes. ​**One step, which in our experience is notorious for not being very robustis automatic skull-stripping.** Therefore, we advocate a hybrid approach that uses SPM for an initial segmentation of the anatomical MRI during the preprocessing. With this segmentation,​ we created a brainmask that provides a robustly skull-stripped image, which is a prerequisite for a correct segmentation in Freesurfer. Although this approach may seem a bit convoluted (you may rightfully ask why we need to redo the segmentation in Freesurfer if we already did it in SPM), the interdependencies between different files generated along the Freesurfer pipeline make tapping into this pipeline at a random point quite complicated. For this reason a large part of the volumetric processing in Freesurfer needs to be done as well.
  
 \\ \\
-In order to be able to use Freesurfer, you need to have a working installation of the package. It can be downloaded from [[http://​surfer.nmr.mgh.harvard.edu/​fswiki|here]]. If you are working at the Center of Neuroimaging of the Donders Institute you can find more versions of Freesurfer under the /​opt/​FreesurferXXX directories. (If you are working at the MPI for Psycholinguistics,​ you should install the software yourself in your directory.) We recommend to use Freesurfer 5.1.0. You can run the commands just copying and pasting them into the terminal window of the Linux system (from where you used also Matlab).+In order to be able to use Freesurfer, you need to have a working installation of the package. It can be downloaded from [[http://​surfer.nmr.mgh.harvard.edu/​fswiki|here]]. If you are working at the Center of Neuroimaging of the Donders Institute you can find more versions of Freesurfer under the /​opt/​FreesurferXXX directories. (If you are working at the MPI for Psycholinguistics,​ you should install the software yourself in your directory.) We recommend to use Freesurfer 5.1.0. ​**You can run the commands ​below by just copying and pasting them into the terminal window of the Linux system (from where you use/​initiate  ​Matlab).** 
 + 
 +**%% I totally skipped past the previous line and got confused with the code below, CAN WE KEEP THE PREVIOUS LINE IN BOLD?? I also added a comment above the first box of code below. ​ ALSO FOR CLARITY, CAN WE INSERT A COMMENT IN THE FIRST CODE BOX THAT RETURNS/​RESUMES TO BEING EXECUTED IN MATLAB?** 
  
 To get started, you need to set up your environmental variables. (Pay attention to the (lack of) spaces.) To get started, you need to set up your environmental variables. (Pay attention to the (lack of) spaces.)
-<​code>​export FREESURFER_HOME=<​path to Freesurfer>​+<​code>​% run this code in linux 
 +export FREESURFER_HOME=<​path to Freesurfer>​
 export SUBJECTS_DIR=<​Subject directory></​code> ​     export SUBJECTS_DIR=<​Subject directory></​code> ​    
 SUBJECTS_DIR is the directory where you will store all the Freesurfer-processed anatomical data of all your subjects. Then, type this command to set up Freesurfer: SUBJECTS_DIR is the directory where you will store all the Freesurfer-processed anatomical data of all your subjects. Then, type this command to set up Freesurfer:
Line 349: Line 353:
 ===== Processing of functional data ===== ===== Processing of functional data =====
 \\ \\
-The following will use the MEG data belonging to Subject01. The file can be obtained from [[ftp://​ftp.fcdonders.nl/​pub/​fieldtrip/​tutorial/​Subject01.zip]].+The following will use the MEG data belonging to Subject01. The file can be obtained from [[ftp://​ftp.fieldtriptoolbox.org/​pub/​fieldtrip/​tutorial/​Subject01.zip]].
 For both preprocessing and averaging, we will follow the steps that have been written in the [[tutorial:​eventrelatedaveraging|Event related averaging and planar gradient]] tutorial. We will use trials belonging to two conditions (FC and FIC) and we will calculate their difference. For both preprocessing and averaging, we will follow the steps that have been written in the [[tutorial:​eventrelatedaveraging|Event related averaging and planar gradient]] tutorial. We will use trials belonging to two conditions (FC and FIC) and we will calculate their difference.
  
Line 472: Line 476:
  
 Functions and tutorial pages that show how to average, and how to analyze statistically source-reconstructions across subjects or how to compare those to a template brain are still under development. Functions and tutorial pages that show how to average, and how to analyze statistically source-reconstructions across subjects or how to compare those to a template brain are still under development.
 +