Doxygen Source Code Documentation
ShowRegressors.m
Go to the documentation of this file.00001 function [err] = ShowRegressors (Task)
00002 %
00003 % [err] = ShowRegressors ()
00004 %
00005 %Purpose:
00006 %
00007 % Gang
00008 %
00009 %Input Parameters:
00010 %
00011 %
00012 %
00013 %Output Parameters:
00014 % err : 0 No Problem
00015 % : 1 Problems
00016 %
00017 %
00018 %
00019 %Key Terms:
00020 %
00021 %More Info :
00022 %
00023 %
00024 %
00025 %
00026 % Author : Ziad Saad
00027 % Date : Fri Jul 18 15:24:43 EDT 2003
00028 % SSCC/NIMH/ National Institutes of Health, Bethesda Maryland
00029
00030
00031 %Define the function name for easy referencing
00032 FuncName = 'ShowRegressors';
00033
00034 %Debug Flag
00035 DBG = 1;
00036
00037 %initailize return variables
00038 err = 1;
00039
00040 figure(1); clf
00041 N_tasks = length(Task);
00042 %ln_style=['b' 'g' 'r' 'c' 'm' 'y' 'k' 'b-'];
00043 m=colormap;
00044 nm = rand(size(m,1),1); [nm, is] = sort(nm);
00045 m(:,1) = m(is,1);
00046 nm = rand(size(m,1),1); [nm, is] = sort(nm);
00047 m(:,2) = m(is,2);
00048 nm = rand(size(m,1),1); [nm, is] = sort(nm);
00049 m(:,3) = m(is,3);
00050
00051 if (N_tasks),
00052 for (i=1:1:N_tasks),
00053 subplot (N_tasks,1,i);
00054 for (j=1:1:size(Task(i).StimReg,1)),
00055 % plot (Task(i).StimReg', ln_style(j)); hold on
00056 plot (Task(i).StimReg(j,:)', 'color', m(j,:)); hold on
00057 end
00058 ylabel(sprintf('%s', Task(i).StimTime));
00059 end
00060 end
00061
00062 figure(2);clf
00063 if (N_tasks),
00064 for (i=1:1:N_tasks),
00065 % subplot (N_tasks,1,i);
00066 for (j=1:1:size(Task(i).StimReg,1)),
00067 plot (Task(i).StimReg(j,:)', 'color', m(i*j,:)); hold on
00068 % plot (Task(i).StimReg', ln_style(i)); hold on
00069 end
00070 end
00071 end
00072 title('All Regressors Together');
00073
00074 drawnow;
00075
00076 err = 0;
00077 return;
00078