This is a static copy of a profile report

Home

importdata>isvaliddata (4 calls, 0.022 sec)
Generated 05-Aug-2011 13:01:22 using cpu time.
subfunction in file /usr/local/MATLAB/R2011a/toolbox/matlab/iofun/importdata.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
importdata>analyzesubfunction4
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
619
numHeaderCols = maxNotData(cel...
40.011 s50.0%
617
[cellstring indices] = split(f...
40.011 s50.0%
634
end
40 s0%
629
end
40 s0%
628
status = 1;
40 s0%
All other lines  0 s0%
Totals  0.022 s100% 
Children (called functions)

Function NameFunction TypeCallsTotal Time% TimeTime Plot
importdata>maxNotDatasubfunction40.011 s50.0%
importdata>splitsubfunction40.011 s50.0%
importdata>isdatasubfunction40 s0%
Self time (built-ins, overhead, etc.)  0 s0%
Totals  0.022 s100% 
Code Analyzer results
Line numberMessage
Coverage results
[ Show coverage for parent directory ]
Total lines in function50
Non-code lines (comments, blank lines)11
Code lines (lines that can run)39
Code lines that did run23
Code lines that did not run16
Coverage (did run/can run)58.97 %
Function listing
   time   calls  line
585 function [status, numHeaderCols, numHeaderChars] = isvaliddata(fileString, delim)
586 % ISVALIDDATA delimiters and all numbers or e or + or . or -
587 % what about single columns???
588
4 589 numHeaderCols = 0;
4 590 numHeaderChars = 0;
591
4 592 if isempty(delim.printed)
593 % with no delimiter, the line must be all numbers, +, . or -
594 status = isdata(fileString);
595 return
596 end
597
4 598 status = 0;
4 599 if ~strcmp(delim.printed,'"')
4 600 fileString = regexprep(fileString, '"[^"]*"','""');
4 601 end
4 602 delims = strfind(fileString, delim.printed);
4 603 if isempty(delims)
604 checkstring = fileString;
605 if isempty(regexp(checkstring, '\S', 'once'))
606 % Just a blank line, not actually data.
607 status = 0;
608 return
609 end
4 610 else
4 611 checkstring = fileString(delims(end)+1:end);
4 612 end
613
614 % if there is data at the end of the line, it's legit
4 615 if isdata(checkstring)
4 616 try
0.01 4 617 [cellstring indices] = split(fileString, delim);
4 618 numNonEmptyCols = find(cellfun('isempty',deblank(cellstring)) == false, 1, 'last');
0.01 4 619 numHeaderCols = maxNotData(cellstring);
620 % use contents of 1st data cell to find num leading chars
4 621 if numHeaderCols > 0
622 numHeaderChars = indices(numHeaderCols);
623 end
4 624 if (numHeaderCols == numNonEmptyCols)
625 numHeaderCols = 0;
626 numHeaderChars = 0;
4 627 else
4 628 status = 1;
4 629 end
630 catch exception %#ok<NASGU>
631 numHeaderCols = 0;
632 numHeaderChars = 0;
633 end
4 634 end

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