cell.strmatch (87 calls, 0.050 sec)
Generated 14-Nov-2016 07:47:10 using cpu time.
function in file /usr/local/MATLAB/MATLAB_Production_Server/R2015a/toolbox/matlab/strfun/@cell/strmatch.m
Copy to new window for comparing multiple runs
Function Name | Function Type | Calls |
optimset | function | 78 |
saveas | function | 9 |
Line Number | Code | Calls | Total Time | % Time | Time Plot |
26 | out = strmatch(str,strs); | 84 | 0.040 s | 80.0% | ![]() |
16 | if iscellstr(strs), strs = cha... | 87 | 0.010 s | 20.0% | ![]() |
29 | end | 3 | 0 s | 0% | ![]() |
28 | out = strmatch(str,strs,flag); | 3 | 0 s | 0% | ![]() |
27 | else | 3 | 0 s | 0% | ![]() |
All other lines | 0 s | 0% | ![]() | ||
Totals | 0.050 s | 100% |
Function Name | Function Type | Calls | Total Time | % Time | Time Plot |
strmatch | function | 87 | 0.040 s | 80.0% | ![]() |
Self time (built-ins, overhead, etc.) | 0.010 s | 20.0% | ![]() | ||
Totals | 0.050 s | 100% |
Total lines in function | 29 |
Non-code lines (comments, blank lines) | 14 |
Code lines (lines that can run) | 15 |
Code lines that did run | 11 |
Code lines that did not run | 4 |
Coverage (did run/can run) | 73.33 % |
time | calls | line | |
---|---|---|---|
1 | function out = strmatch(str,strs,flag) | ||
2 | %STRMATCH Cell array based string matching. | ||
3 | % Implementation of STRMATCH for cell arrays of strings. | ||
4 | % | ||
5 | % STRMATCH will be removed in a future release. Use STRNCMP instead. | ||
6 | % | ||
7 | % See also STRMATCH. | ||
8 | |||
9 | % Loren Dean 9/19/95 | ||
10 | % Copyright 1984-2011 The MathWorks, Inc. | ||
11 | |||
87 | 12 | narginchk(2,3); | |
13 | |||
87 | 14 | if isempty(strs), out = []; return; end | |
87 | 15 | if iscellstr(str), str = char(str); end | |
0.01 | 87 | 16 | if iscellstr(strs), strs = char(strs); end |
17 | |||
87 | 18 | if ~ischar(str) || ~ischar(strs) | |
19 | error(message('MATLAB:strmatch:InvalidInput')); | ||
20 | end | ||
87 | 21 | if (nargin==3) && ~ischar(flag) | |
22 | error(message('MATLAB:strmatch:InvalidFlagInput')); | ||
23 | end | ||
24 | |||
87 | 25 | if nargin==2, | |
0.04 | 84 | 26 | out = strmatch(str,strs); |
3 | 27 | else | |
3 | 28 | out = strmatch(str,strs,flag); | |
3 | 29 | end |
Other subfunctions in this file are not included in this listing.