This is a static copy of a profile report

Home

skim>date2str (2 calls, 0.011 sec)
Generated 05-Aug-2011 13:00:43 using cpu time.
subfunction in file /home/LeechJ/cbass_analysis/reduc/support/skim.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
skimfunction2
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
217
sec=num2str(sec,3);
10.011 s100.0%
225
s.month=month;
20 s0%
224
s.second=sec;
20 s0%
223
s.year=year;
20 s0%
221
end
10 s0%
All other lines  0 s0%
Totals  0.011 s100% 
Children (called functions)

Function NameFunction TypeCallsTotal Time% TimeTime Plot
num2strfunction80.011 s100.0%
strcatfunction60 s0%
rmfieldfunction60 s0%
Self time (built-ins, overhead, etc.)  0 s0%
Totals  0.011 s100% 
Code Analyzer results
Line numberMessage
Coverage results
[ Show coverage for parent directory ]
Total lines in function27
Non-code lines (comments, blank lines)5
Code lines (lines that can run)22
Code lines that did run22
Code lines that did not run0
Coverage (did run/can run)100.00 %
Function listing
   time   calls  line
199 function s=date2str(s)
200
2 201 month=s.month;
2 202 sec=s.second;
2 203 year=s.year;
2 204 s=rmfield(s,'month');
2 205 s=rmfield(s,'second');
2 206 s=rmfield(s,'year');
2 207 n=fieldnames(s);
208
2 209 for i=1:length(n)
6 210 eval(sprintf('s.%s=num2str(s.%s);',n{i},n{i}));
6 211 if (eval(sprintf('length(s.%s)<2',n{i})))
5 212 eval(sprintf('s.%s=strcat(''0'',s.%s);',n{i},n{i}));
5 213 end
6 214 end
215
2 216 if (sec<10)
0.01 1 217 sec=num2str(sec,3);
1 218 sec=strcat('0',sec);
1 219 else
1 220 sec=num2str(sec,4);
1 221 end
222
2 223 s.year=year;
2 224 s.second=sec;
2 225 s.month=month;

Other subfunctions in this file are not included in this listing.