This is a static copy of a profile reportHome
workspacefunc>num2complex (17 calls, 0.000 sec)
Generated 05-Aug-2011 13:01:06 using cpu time.
subfunction in file /usr/local/MATLAB/R2011a/toolbox/matlab/codetools/workspacefunc.m
Copy to new window for comparing multiple runs
Parents (calling functions)
Lines where the most time was spent
No measurable time spent in this functionLine Number | Code | Calls | Total Time | % Time | Time Plot |
268 | end | 17 | 0 s | 0% |  |
267 | end | 17 | 0 s | 0% |  |
266 | outVal = getAbstractValueSumma... | 17 | 0 s | 0% |  |
265 | else | 17 | 0 s | 0% |  |
254 | if islogical(in) | 17 | 0 s | 0% |  |
All other lines | | | 0 s | 0% |  |
Totals | | | 0 s | 0% | |
Children (called functions)
Code Analyzer results
No Code Analyzer messages.Coverage results
[ Show coverage for parent directory ]
Total lines in function | 30 |
Non-code lines (comments, blank lines) | 4 |
Code lines (lines that can run) | 26 |
Code lines that did run | 7 |
Code lines that did not run | 19 |
Coverage (did run/can run) | 26.92 % |
Function listing
time calls line
239 function outVal = num2complex(in)
240 import com.mathworks.widgets.spreadsheet.data.ValueSummaryFactory;
17 241 if builtin('isnumeric', in)
242 if isscalar(in)
243 outVal = createComplexScalar(in);
244 else
245 if isempty(in) || numel(size(in)) > 2 || numel(in) > 10
246 clazz = class(in);
247 outVal = ValueSummaryFactory.getInstance(cast(0, clazz), size(in), ...
248 ~dataviewerhelper('isUnsignedIntegralType', in), isreal(in));
249 else
250 outVal = createComplexVector(in);
251 end
252 end
17 253 else
17 254 if islogical(in)
255 if isscalar(in)
256 if (in)
257 outVal = java.lang.Boolean.TRUE;
258 else
259 outVal = java.lang.Boolean.FALSE;
260 end
261 else
262 % Let it drop to the class-handling code.
263 outVal = getAbstractValueSummaryJ(in);
264 end
17 265 else
17 266 outVal = getAbstractValueSummaryJ(in);
17 267 end
17 268 end
Other subfunctions in this file are not included in this listing.