clear;clc;

clear;clc;

cd /home/subhadip/Autism_AnatNet/austistic_study/Anatomy/With_Skull/T1_volumes/A

referencefile=dir('t1*.nii.gz');
coeffile=dir('coef*.nii');

for l=1:length(referencefile)
    
  outvol=strrep(referencefile(l).name,'t1','aal990_on_t1');
    
 [status currdir] = system([' applywarp -i AAL-990.nii  -o ' outvol ' -r ' referencefile(l).name ' -w ' coeffile(l).name ' --interp=nn '])
 
end


