aa0fb379218f6b86818442412779930261a7d51a
Christoph Budziszewski working: SingleSubject, Coo...

Christoph Budziszewski authored 15 years ago

1) function subjectStruct  = runROIImageMaskMode(args)
Christoph Budziszewski moved things

Christoph Budziszewski authored 15 years ago

2) 
Christoph Budziszewski roi image working

Christoph Budziszewski authored 15 years ago

3) subjects = args.subjects;
Christoph Budziszewski coordTabel works for JZ006

Christoph Budziszewski authored 15 years ago

4)    
Christoph Budziszewski working: SingleSubject, Coo...

Christoph Budziszewski authored 15 years ago

5) nSubjects = numel(subjects);
Christoph Budziszewski coordTabel works for JZ006

Christoph Budziszewski authored 15 years ago

6) sessionlist = args.sessionList;
Christoph Budziszewski normalization features enabled

Christoph Budziszewski authored 15 years ago

7) pstopts = args.psthOpts;
8) pstopts.eventList = args.eventList;
9) pstopts.sessionList = sessionlist;
Christoph Budziszewski roi image working

Christoph Budziszewski authored 15 years ago

10) 
Christoph Budziszewski first plot button. not work...

Christoph Budziszewski authored 15 years ago

11) disp(sprintf('batch processing  %g subjects.',nSubjects));
Christoph Budziszewski roi image working

Christoph Budziszewski authored 15 years ago

12) 
13) for s = 1:nSubjects
14)     subjectStruct{s}.dir = fullfile(args.basedir,cell2mat(subjects(s)));
Christoph Budziszewski coordTabel works for JZ006

Christoph Budziszewski authored 15 years ago

15)     d = load(fullfile(subjectStruct{s}.dir,'results','SPM.mat'));
16)     subjectStruct{s}.des = d.SPM;
Christoph Budziszewski roi image working

Christoph Budziszewski authored 15 years ago

17)     subjectStruct{s}.name = cell2mat(subjects(s));
18)     subjectStruct{s}.roiFile = ui_selectRoiImage(...
19)         sprintf('Select ROI Files for %s',subjectStruct{s}.name),...
20)         fullfile(subjectStruct{s}.dir,'results','roi'));
21) end
22) 
23) 
24) 
25) for s = 1:nSubjects
26)     % load image data
27)    
28)     disp('fetching volume definitions, please wait');
Christoph Budziszewski coordTabel works for JZ006

Christoph Budziszewski authored 15 years ago

29)     subjectStruct{s}.volumes = spm_vol(getImageFileList(subjectStruct{s}.dir,sessionlist,args.mask));
Christoph Budziszewski roi image working

Christoph Budziszewski authored 15 years ago

30) 
31)     disp('computing volume values, please wait');
Christoph Budziszewski coordTabel works for JZ006

Christoph Budziszewski authored 15 years ago

32)     
Christoph Budziszewski debugging

Christoph Budziszewski authored 14 years ago

33)     [extr x y z] = calculateRoiImageData(subjectStruct{s}.volumes,subjectStruct{s}.roiFile);
Christoph Budziszewski schwimmen.

Christoph Budziszewski authored 15 years ago

34)     
35)     nVoxel = size(extr(1).dat,1);
36) 
Christoph Budziszewski roi image working

Christoph Budziszewski authored 15 years ago

37)     % calculate psth
Christoph Budziszewski coordTabel works for JZ006

Christoph Budziszewski authored 15 years ago

38)     pstopts.des = subjectStruct{s}.des;
39) 
40)     disp('computing psth');
Christoph Budziszewski schwimmen.

Christoph Budziszewski authored 15 years ago

41)     for iVoxel = 1:nVoxel
Christoph Budziszewski debugging

Christoph Budziszewski authored 14 years ago

42)         [ x(iVoxel) y(iVoxel) z(iVoxel)]
Christoph Budziszewski schwimmen.

Christoph Budziszewski authored 15 years ago

43)         rawdata = [];
44)         for iImage = 1:length(extr);
45)             tmp = extr(iImage);
46)             rawdata = [rawdata tmp.dat(iVoxel)];
47)         end
48)         subjectStruct{s}.pst{iVoxel} = calculatePST(args.timeline,pstopts,rawdata);
49)     end
Christoph Budziszewski coordTabel works for JZ006

Christoph Budziszewski authored 15 years ago

50)     disp('done');
Christoph Budziszewski moved things

Christoph Budziszewski authored 15 years ago

51) end
52) 
Christoph Budziszewski working: SingleSubject, Coo...

Christoph Budziszewski authored 15 years ago

53) % assignin('base',SVMCROSSVAL_SUBJECTSTRUCT_NAME,subjectStruct);
Christoph Budziszewski roi image working

Christoph Budziszewski authored 15 years ago

54)