Home > vbmeg > functions > brain > vb_copy_std_brain.m

vb_copy_std_brain

PURPOSE ^

Copy standard brain files to save_dir for group analysis

SYNOPSIS ^

function vb_copy_std_brain(save_dir, Nvertex)

DESCRIPTION ^

 Copy standard brain files to save_dir for group analysis

  vb_copy_std_brain(save_dir, Nvertex)

 [history]
 Ver.2.0 New version for group analysis
 2015-12-27 M. Sato 


 Copyright (C) 2011, ATR All Rights Reserved.
 License : New BSD License(see VBMEG_LICENSE.txt)

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function    vb_copy_std_brain(save_dir, Nvertex)
0002 % Copy standard brain files to save_dir for group analysis
0003 %
0004 %  vb_copy_std_brain(save_dir, Nvertex)
0005 %
0006 % [history]
0007 % Ver.2.0 New version for group analysis
0008 % 2015-12-27 M. Sato
0009 %
0010 %
0011 % Copyright (C) 2011, ATR All Rights Reserved.
0012 % License : New BSD License(see VBMEG_LICENSE.txt)
0013 
0014 
0015 % --- std_brain
0016 [std_parm, proj_root] = vb_set_icbm152(Nvertex);
0017 
0018 std_brain = [proj_root filesep std_parm.brain_file];
0019 std_area  = [proj_root filesep std_parm.area_file];
0020 std_act   = [proj_root filesep std_parm.act_file ];
0021 
0022 std_area_aal  = [proj_root filesep std_parm.area_aal];
0023 std_act_aal   = [proj_root filesep std_parm.act_aal ];
0024 std_area_brd  = [proj_root filesep std_parm.area_brodmann];
0025 std_act_brd   = [proj_root filesep std_parm.act_brodmann ];
0026 
0027 std_id    = std_parm.std_id   ;
0028 std_dir   = std_parm.std_dir   ;
0029 
0030 std_image     = [std_dir std_id '.img'];
0031 std_hdr       = [std_dir std_id '.hdr'];
0032 
0033 % --- Copy of std_brain in save_dir
0034 save_image     = [save_dir  '/std_copy.img'  ];
0035 save_hdr       = [save_dir  '/std_copy.hdr'  ];
0036 
0037 %save_brain_mni = [save_dir  '/std_mni.brain.mat'];  % V = Vmni
0038 save_brain_spm = [save_dir  '/std_copy.brain.mat']; % V = Vspm
0039 
0040 save_act       = [save_dir  '/std_copy.act.mat'  ];
0041 save_area      = [save_dir  '/std_copy.area.mat' ];
0042 
0043 save_act_aal   = [save_dir  '/std_copy_aal.act.mat'];
0044 save_act_brd   = [save_dir  '/std_copy_brodmann.act.mat'];
0045 save_area_aal  = [save_dir  '/std_copy_aal.area.mat'];
0046 save_area_brd  = [save_dir  '/std_copy_brodmann.area.mat'];
0047 
0048 % --- Copy file
0049 if exist(std_image ,'file'), copyfile(std_image ,save_image  ); end;
0050 if exist(std_hdr   ,'file'), copyfile(std_hdr   ,save_hdr    ); end;
0051 
0052 %if exist(std_brain ,'file'), copyfile(std_brain ,save_brain_mni); end;
0053 if exist(std_brain ,'file'), copyfile(std_brain ,save_brain_spm); end;
0054 
0055 if exist(std_act   ,'file'), copyfile(std_act   ,save_act  ); end;
0056 if exist(std_area  ,'file'), copyfile(std_area  ,save_area );end;
0057 
0058 if exist(std_act_aal ,'file'), copyfile(std_act_aal ,save_act_aal); end;
0059 if exist(std_act_brd ,'file'), copyfile(std_act_brd ,save_act_brd); end;
0060 if exist(std_area_aal,'file'), copyfile(std_area_aal,save_area_aal);end;
0061 if exist(std_area_brd,'file'), copyfile(std_area_brd,save_area_brd);end;
0062 
0063 return
0064 %
0065 %% --- Save MNI [m] coordinate in std_brain as V
0066 %V = vb_load_cortex(std_brain,'MNI');
0067 %
0068 %vb_save([save_brain_mni],'V');

Generated on Mon 22-May-2023 06:53:56 by m2html © 2005