Christoph Budziszewski commited on 2009-03-16 20:09:44
Zeige 5 geänderte Dateien mit 14 Einfügungen und 6 Löschungen.
git-svn-id: https://svn.discofish.de/MATLAB/spmtoolbox/SVMCrossVal@157 83ab2cfd-5345-466c-8aeb-2b2739fb922d
... | ... |
@@ -1,6 +1,6 @@ |
1 | 1 |
function outputStruct = calculateDecodePerformance(header,subjectStruct,svmopts) |
2 | 2 |
outputStruct = struct; |
3 |
-RANDOMIZE_DATAPOINTS = 1; |
|
3 |
+RANDOMIZE_DATAPOINTS = header.svmrnd; |
|
4 | 4 |
|
5 | 5 |
timeline = header.timeline; |
6 | 6 |
timeline.frameShiftStart = header.frameShift.frameShiftStart; |
... | ... |
@@ -6,8 +6,7 @@ decode.decodePerformance = []; |
6 | 6 |
decode.rawTimeCourse = []; |
7 | 7 |
|
8 | 8 |
nSubjects = numel(subjectdata); |
9 |
-% disp(sprintf('we have %g subjects. Press ANY-Key to continue.\n Use Retrun if your Keyboard lacks the ANY-Key.',numel(subjectdata))); |
|
10 |
-% pause |
|
9 |
+ |
|
11 | 10 |
disp(sprintf('batch processing %g subjects',nSubjects)); |
12 | 11 |
|
13 | 12 |
for subjectDataID = 1:nSubjects |
... | ... |
@@ -13,8 +13,10 @@ DEFAULT.classdefstring = 'left,\t[9,11,13]\nright,\t[10,12,14]'; |
13 | 13 |
DEFAULT.voxelstring = 'SPL l + [ 0, 0, 0] \nSPL r + [ 0, 0, 0]\n'; |
14 | 14 |
DEFAULT.svmoptstring = '-s 0 -t 0 -c 1'; |
15 | 15 |
DEFAULT.svmnfold = '6'; |
16 |
+DEFAULT.svmrnd = 1; |
|
16 | 17 |
DEFAULT.searchlightradius = 0; |
17 | 18 |
|
19 |
+ |
|
18 | 20 |
DEFAULT.wd = fullfile('d:','Analyze','Choice','24pilot'); |
19 | 21 |
|
20 | 22 |
% Initialize and hide the GUI as it is being constructed. |
... | ... |
@@ -307,12 +309,18 @@ pSVM = uipanel(parent,'Units','normalized','Position',[0 0.4 0.5 0.4]); |
307 | 309 |
set(pSVM,'Title','SVM Classification'); |
308 | 310 |
set(pSVM,'BackgroundColor',basecolor); |
309 | 311 |
|
310 |
- model.txtSVMopts = createTextField(pSVM,[0 0.75 1 0.25],DEFAULT.svmoptstring); |
|
312 |
+ model.txtSVMopts = createTextField(pSVM,[0 0.83 1 0.16],DEFAULT.svmoptstring); |
|
311 | 313 |
set(model.txtSVMopts,'HorizontalAlignment','left'); |
312 | 314 |
|
313 |
- model.txtSVMnfold = createTextField(pSVM,[0.0 0.50 0.5 0.25],DEFAULT.svmnfold); |
|
315 |
+ model.txtSVMnfold = createTextField(pSVM,[0.0 0.66 0.5 0.16],DEFAULT.svmnfold); |
|
314 | 316 |
createLabel(pSVM,[0.5 0.50 0.5 0.25 ],'-Fold CrossVal'); |
315 | 317 |
|
318 |
+ model.chkSVMrnd = uicontrol(pSVM,'Style','checkbox','Units','normalized','Position',[0.1 0.50 1 0.16]); |
|
319 |
+ set(model.chkSVMrnd,'String','Randomize Datapoints'); |
|
320 |
+ set(model.chkSVMrnd,'BackgroundColor','w'); |
|
321 |
+ set(model.chkSVMrnd,'Value',DEFAULT.svmrnd); |
|
322 |
+ |
|
323 |
+ |
|
316 | 324 |
pSOM = uipanel(parent,'Units','normalized','Position',[0.5 0.4 0.5 0.4]); |
317 | 325 |
set(pSOM,'Title','SOM Classification'); |
318 | 326 |
set(pSOM,'BackgroundColor',basecolor); |
... | ... |
@@ -8,7 +8,7 @@ if(nSubjects < 2) |
8 | 8 |
error('SVMCrossVal:xsvmSubjectLoop:tooFewSubjects','You need at least 2 Subjects in this Across-Subject analysis!'); |
9 | 9 |
end |
10 | 10 |
|
11 |
-RANDOMIZE_DATAPOINTS = 0; |
|
11 |
+RANDOMIZE_DATAPOINTS = 1; |
|
12 | 12 |
|
13 | 13 |
decode = struct; |
14 | 14 |
decode.decodePerformance = []; |
15 | 15 |