SpreadsheetInputs>SpreadsheetInputs.setSheet (Calls: 4, Time: 0.004 s)
Generated 04-Jun-2021 04:11:21 using performance time.
class method in file C:\Program Files\MATLAB\R2020b\toolbox\shared\io\general\+matlab\+io\+internal\+shared\SpreadsheetInputs.m
Copy to new window for comparing multiple runs
Function Name | Function Type | Calls |
...gt;AcceptsSheetNameOrNumber.set.Sheet | class method | 4 |
Line Number | Code | Calls | Total Time | % Time | Time Plot |
182 | if n < 0 || n > 31 || an... | 4 | 0.003 s | 80.2% | |
180 | elseif ischar(rhs) && ... | 4 | 0.000 s | 5.5% | |
189 | if isempty(rhs) | 4 | 0.000 s | 2.9% | |
177 | rhs = convertStringsToChars(rh... | 4 | 0.000 s | 2.5% | |
192 | end | 4 | 0.000 s | 0.0% | |
All other lines | 0.000 s | 8.8% | |||
Totals | 0.004 s | 100% |
Function Name | Function Type | Calls | Total Time | % Time | Time Plot |
ismember | function | 4 | 0.003 s | 72.0% | |
Self time (built-ins, overhead, etc.) | 0.001 s | 28.0% | |||
Totals | 0.004 s | 100% |
Total lines in function | 17 |
Non-code lines (comments, blank lines) | 3 |
Code lines (lines that can run) | 14 |
Code lines that did run | 11 |
Code lines that did not run | 3 |
Coverage (did run/can run) | 78.57 % |
time | Calls | line | |
---|---|---|---|
176 | function [rhs,obj] = setSheet(obj,rhs) | ||
< 0.001 | 4 | 177 | rhs = convertStringsToChars(rhs); |
< 0.001 | 4 | 178 | if isnumeric(rhs) && isscalar(rhs) && rhs > 0 && floor(rhs)==rhs |
179 | % nothing needed | ||
< 0.001 | 4 | 180 | elseif ischar(rhs) && (isrow(rhs) || isempty(rhs)) |
< 0.001 | 4 | 181 | n = numel(rhs); |
0.003 | 4 | 182 | if n < 0 || n > 31 || any(ismember(rhs,':\/?*[]')) |
183 | error(message('MATLAB:spreadsheet:book:invalidSheetName')); | ||
< 0.001 | 4 | 184 | end |
185 | else | ||
186 | error(message('MATLAB:spreadsheet:importoptions:BadSheet')); | ||
< 0.001 | 4 | 187 | end |
188 | |||
< 0.001 | 4 | 189 | if isempty(rhs) |
< 0.001 | 4 | 190 | rhs = ''; |
< 0.001 | 4 | 191 | end |
< 0.001 | 4 | 192 | end |
Other subfunctions in this file are not included in this listing.