This is a static copy of a profile report

Home

imread>parse_inputs (1 call, 0.000 sec)
Generated 15-Mar-2007 12:01:56 using real time.
M-subfunction in file C:\Program Files\MATLAB71\toolbox\matlab\imagesci\imread.m
[Copy to new window for comparing multiple runs]

Parents (calling functions)

Function NameFunction TypeCalls
imreadM-function1
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
338
filename = '';
10.000 s79.2%
341
msg = '';
10.000 s8.0%
339
format = '';
10.000 s7.1%
340
extraArgs = {};
10.000 s5.7%
354
filename = varargin{1};
10 s0%
Other lines & overhead  0 s0%
Totals  0.000 s100% 
Children (called functions)
No children
M-Lint results
No M-Lint messages.
Coverage results
[ Show coverage for parent directory ]
Total lines in file42
Non-code lines (comments, blank lines)18
Code lines (lines that can run)24
Code lines that did run8
Code lines that did not run16
Coverage (did run/can run)33.33 %
Function listing
   time   calls  line
336 parse_inputs(varargin)
337
< 0.01 1 338 filename = '';
< 0.01 1 339 format = '';
< 0.01 1 340 extraArgs = {};
< 0.01 1 341 msg = '';
342
343 % Parse arguments based on their number.
1 344 switch(nargin)
1 345 case 0
346
347 % Not allowed.
348 msg = 'Too few input arguments.';
349 return;
350
1 351 case 1
352
353 % Filename only.
1 354 filename = varargin{1};
355
356 otherwise
357
358 % Filename and format or other arguments.
359 filename = varargin{1};
360
361 % Check whether second argument is a format.
362 if (ischar(varargin{2}))
363 fmt_s = imformats(varargin{2});
364 else
365 fmt_s = struct([]);
366 end
367
368 if (~isempty(fmt_s))
369 % The argument matches a format.
370 format = varargin{2};
371 extraArgs = varargin(3:end);
372 else
373 % The argument begins the format-specific parameters.
374 extraArgs = varargin(2:end);
375 end
376
377 end