multiple searchlight radii, bugfix
Christoph Budziszewski

Christoph Budziszewski commited on 2009-04-26 22:14:15
Zeige 1 geänderte Dateien mit 4 Einfügungen und 3 Löschungen.


git-svn-id: https://svn.discofish.de/MATLAB/spmtoolbox/SVMCrossVal@187 83ab2cfd-5345-466c-8aeb-2b2739fb922d
... ...
@@ -142,7 +142,7 @@ for timeShiftIdx = fbsTimeLine
142 142
     frameStartIdx  = floor(-globalStart+1+timeShiftIdx - 0.5*decodeDuration);
143 143
     frameEndIdx    = min(ceil(frameStartIdx+decodeDuration + 0.5*decodeDuration),-globalStart+globalEnd);
144 144
 
145
-        for r = radiusList
145
+        for r = 1:length(radiusList)
146 146
             img3D{r} = zeros(size(mask_image)); %output image prepare
147 147
         end
148 148
         
... ...
@@ -151,7 +151,8 @@ for timeShiftIdx = fbsTimeLine
151 151
                 display(sprintf('Status: %03u / %03u Timepoints, %05u / %05u Coordinates',find(fbsTimeLine == timeShiftIdx),length(fbsTimeLine),iVoxel,nVoxel));
152 152
                 pause(0.001) %flush system event queue
153 153
             end
154
-            for radius = radiusList
154
+            for rIdx  = 1: length(radiusList)
155
+                radius = radiusList(rIdx);
155 156
                 % get surrounding coordinate-IDs within radius
156 157
                 sphere = fbs_buildSphere(mapping,iVoxel,radius,vdim);
157 158
                 
... ...
@@ -185,7 +186,7 @@ for timeShiftIdx = fbsTimeLine
185 186
                 y = coord(2);
186 187
                 z = coord(3);
187 188
                 
188
-                img3D{radius}(x,y,z) = ((decode/100)-0.5)*2; % range [-1:1]
189
+                img3D{rIdx}(x,y,z) = ((decode/100)-0.5)*2; % range [-1:1]
189 190
                 
190 191
             end %for each radius
191 192
         end %for each voxel
192 193