Christoph Budziszewski
add trajectory plot
Christoph Budziszewski commited 643a193 at 2009-10-14 14:45:40
plotDecodePerformance.m
function plotDecodePerformance(type,decode,subjectData)
header = decode.header;
timeline = header.timeline;
frameshift = header.frameShift;
psthStart = timeline.psthStart;
psthEnd = timeline.psthEnd;
frameStart = frameshift.frameShiftStart;
frameEnd = frameshift.frameShiftEnd;
nClasses = numel(header.classDef.labelCells);
decodePerformance = decode.decodePerformance;
psth = decode.rawTimeCourse;
ert = psth; % Rename to EventRelatedTimeline
SubjectID = subjectData;
nSubjects = size(SubjectID,2);
nTrials = getNTrials(psth);
f = figure;
hold on;
chanceLevel = 100/nClasses;
axis([psthStart psthEnd 0 100])
xlabel('time [sec]');
ylabel('decode performance [%]');
plottime= tic;
switch type
case 'psth'
plotPSTH(ert,psthStart,psthEnd);
case 'trajectory'
plotTrajectory(ert,psthStart,psthEnd);
case 'trajectory3'
plotTrajectory3(ert);
case 'simple'
plotDecodePerformanceWithSE(frameStart,frameEnd,decodePerformance)
plot([psthStart psthEnd],[chanceLevel chanceLevel],'k:');
plotBinConfidenceIntervall(psthStart,psthEnd,nTrials,0.05,chanceLevel/100,'--');
plotBinConfidenceIntervall(psthStart,psthEnd,nTrials,0.01,chanceLevel/100,'-.');
plotBinConfidenceIntervall(psthStart,psthEnd,nTrials,0.001,chanceLevel/100,':');
case 'class performance'
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX