git.schokokeks.org
Repositories
Help
Report an Issue
SVMCrossVal.git
Code
Commits
Branches
Tags
Suche
Strukturansicht:
fd18aa8
Branches
Tags
master
SVMCrossVal.git
private
buildTimePointMatrix.m
added 2nd classification method: no crossval, but class performance checks. may not plot correctly with multisubject
Christoph Budziszewski
commited
fd18aa8
at 2009-01-19 18:28:59
buildTimePointMatrix.m
Blame
History
Raw
function timePointMatrix = buildTimePointMatrix(argStruct) pst = argStruct.pst; timeLineStart = argStruct.timeLineStart; timeLineEnd = argStruct.timeLineEnd; globalStart = argStruct.globalStart; globalEnd = argStruct.globalEnd; decodeDuration = argStruct.decodeDuration; eventList = argStruct.eventList; labelMap = argStruct.labelMap; timePointMatrix = {}; %%% build timepoint Matrix for timeShift = timeLineStart:1:timeLineEnd % center timepoint && relative shift frameStart = floor(-globalStart+1+timeShift - 0.5*decodeDuration); frameEnd = min(ceil(frameStart+decodeDuration + 0.5*decodeDuration),-globalStart+globalEnd); %build svm inputmatrix index = timeShift-timeLineStart+1; %Bad 1-indexing :-( timePointMatrix{index} =[]; anyvoxel = 1; for pstConditionGroup = 1:size(pst{1,anyvoxel},2) for dp = 1:size(pst{1,anyvoxel}{1,pstConditionGroup},1) % data point row = getSVMLabel(labelMap,eventList(pstConditionGroup,1)); for voxel = 1:size(pst,2) row = [row, pst{1,voxel}{1,pstConditionGroup}(dp,frameStart:frameEnd)]; % label,[value,value,...],[value,value,...]... end timePointMatrix{index} = [timePointMatrix{index}; row]; end end end end