This is a static copy of a profile report

Home

DetectImportOptionsSpreadsheet>DetectImportOptionsSpreadsheet.execute (Calls: 2, Time: 0.221 s)
Generated 04-Jun-2021 04:11:08 using performance time.
class method in file C:\Program Files\MATLAB\R2020b\toolbox\matlab\io\spreadsheet\+matlab\+io\+internal\+functions\DetectImportOptionsSpreadsheet.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
...ptions>DetectImportOptions.executeclass method2
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
38
[opts,func] = func.getOptsFrom...
20.186 s84.3%
32
func.WorkSheet.openBook(func.F...
20.015 s6.6%
39
opts = func.setNonDetectionPro...
20.014 s6.2%
23
checkWrongParamsWrongType(supp...
20.002 s1.0%
37
func.WorkSheet.openSheet(func....
20.002 s0.9%
All other lines  0.002 s1.0%
Totals  0.221 s100% 
Children (called functions)

Function NameFunction TypeCallsTotal Time% TimeTime Plot
...rtOptionsSpreadsheet.getOptsFromSheetclass method20.185 s84.0%
...Spreadsheet.setNonDetectionPropertiesclass method20.013 s6.0%
UsesWorksheet>UsesWorksheet.openBookclass method20.012 s5.3%
...gt;AcceptsSheetNameOrNumber.get.Sheetclass method40.002 s1.1%
...eadsheet>checkWrongParamsWrongTypeclass method20.002 s0.9%
UsesWorksheet>UsesWorksheet.openSheetclass method20.001 s0.3%
getExtensionfunction20.001 s0.2%
...;AcceptsReadableFilename.get.Filenameclass method40.000 s0.1%
Self time (built-ins, overhead, etc.)  0.005 s2.1%
Totals  0.221 s100% 
Code Analyzer results
No Code Analyzer messages.
Coverage results
Show coverage for parent directory
Total lines in function20
Non-code lines (comments, blank lines)5
Code lines (lines that can run)15
Code lines that did run11
Code lines that did not run4
Coverage (did run/can run)73.33 %
Function listing
time 
Calls 
 line
  21 
        function opts = execute(func, supplied)
  22 
            import matlab.io.spreadsheet.internal.*;
  0.002 
      2 
  23
            checkWrongParamsWrongType(supplied); 
  0.001 
      2 
  24
            fmt = getExtension(func.Filename); 
  25 
            % On Windows for ODS and XLSB files error when UseExcel is set to false by the user
< 0.001 
      2 
  26
            if(ispc && contains(fmt, {'ods', 'xlsb'}, 'IgnoreCase',true)...  
  27 
                && isfield(supplied,'UseExcel') && supplied.UseExcel && ~func.UseExcel)
  28 
                error(message('MATLAB:spreadsheet:book:fileTypeUnsupported', fmt));
< 0.001 
      2 
  29
            end 
  30 

< 0.001 
      2 
  31
            if isfield(supplied,'UseExcel') 
  0.015 
      2 
  32
                func.WorkSheet.openBook(func.Filename, func.Sheet, fmt, func.UseExcel); 
  33 
            else
  34 
                % detectImportOptions does not have a 'UseExcel' parameter and relies on 'UseExcel' false by default
  35 
                func.WorkSheet.openBook(func.Filename, func.Sheet, fmt, false);
      2 
  36
            end 
  0.002 
      2 
  37
            func.WorkSheet.openSheet(func.Sheet); 
  0.186 
      2 
  38
            [opts,func] = func.getOptsFromSheet(supplied); 
  0.014 
      2 
  39
            opts = func.setNonDetectionProperties(opts); 
< 0.001 
      2 
  40
        end 

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