#!/bin/tcsh -f if ("$1" == "-clean") then \rm -f lh.OccROIs+orig* \rm -f lh.BigROIs+orig* goto END endif if ( ! -f lh.OccROIs.niml.dset || \ ! -f lh.BigROIs.niml.dset) then echo "" echo "Missing lh.OccROIs.niml.dset or lh.BigROIs.niml.dset" echo "First run:" echo " tcsh run_ROI2dataset" echo "then rerun tcsh `basename $0`" echo "" goto END endif #delete output file (from previous run) if ( ! -f lh.OccROIs+orig.HEAD) then #Turn the surface ROIs into volume ROIs 3dSurf2Vol -spec ../SurfData/SUMA/std.DemoSubj_lh.spec \ -surf_A lh.smoothwm.asc \ -surf_B lh.pial.asc \ -sv DemoSubj_SurfVol_Alnd_Exp+orig \ -grid_parent DemoSubj_EccExpavir+orig \ -map_func ave \ -f_steps 10 \ -f_p1_mm -0.5 -f_pn_mm 0.5 \ -sdata lh.OccROIs.niml.dset \ -prefix lh.OccROIs else echo "lh.OccROIs+orig.HEAD is already on disk" endif #Turn ROI to surf ROI if ( ! -f lh.BigROIs+orig.HEAD) then #Turn the surface ROIs into volume ROIs 3dSurf2Vol -spec ../SurfData/SUMA/std.DemoSubj_lh.spec \ -surf_A lh.smoothwm.asc \ -surf_B lh.pial.asc \ -sv DemoSubj_SurfVol_Alnd_Exp+orig \ -grid_parent DemoSubj_SurfVol_Alnd_Exp+orig \ -map_func mode \ -f_steps 20 \ -sdata lh.BigROIs.niml.dset \ -prefix lh.BigROIs else echo "lh.BigROIs+orig.HEAD is already on disk" endif #For a more solid ROI, checkout example 1 of SurfPatch -help END: