This is a static copy of a profile report

Home

squeeze (Calls: 2639, Time: 0.051 s)
Generated 18-Jul-2020 08:10:24 using performance time.
function in file /Applications/MATLAB_R2020a.app/toolbox/matlab/elmat/squeeze.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
hhsave_VFI_3OCfunction2639
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
23
siz = [siz ones(1,2-length(siz...
26390.019 s38.3%
22
siz(siz==1) = []; % Remove sin...
26390.011 s22.6%
24
b = reshape(a,siz);
26390.005 s9.0%
27
end
26390.003 s5.8%
21
siz = size(a);
26390.002 s3.4%
All other lines  0.011 s20.8%
Totals  0.051 s100% 
Children (called functions)
No children
Code Analyzer results
No Code Analyzer messages.
Coverage results
Show coverage for parent directory
Total lines in function27
Non-code lines (comments, blank lines)16
Code lines (lines that can run)11
Code lines that did run8
Code lines that did not run3
Coverage (did run/can run)72.73 %
Function listing
time 
Calls 
 line
   1 
function b = squeeze(a)
   2 
%SQUEEZE Remove singleton dimensions.
   3 
%   B = SQUEEZE(A) returns an array B with the same elements as
   4 
%   A but with all the singleton dimensions removed.  A singleton
   5 
%   is a dimension such that size(A,dim)==1.  2-D arrays are
   6 
%   unaffected by squeeze so that row vectors remain rows.
   7 
%
   8 
%   For example,
   9 
%       squeeze(rand(2,1,3))
  10 
%   is 2-by-3.
  11 
%
  12 
%   See also SHIFTDIM.
  13 

  14 
%   Copyright 1984-2010 The MathWorks, Inc. 
  15 

< 0.001 
   2639 
  16
if nargin==0  
  17 
  error(message('MATLAB:squeeze:NotEnoughInputs')); 
< 0.001 
   2639 
  18
end 
  19 

< 0.001 
   2639 
  20
if ~ismatrix(a) 
  0.002 
   2639 
  21
  siz = size(a); 
  0.011 
   2639 
  22
  siz(siz==1) = []; % Remove singleton dimensions. 
  0.019 
   2639 
  23
  siz = [siz ones(1,2-length(siz))]; % Make sure siz is at least 2-D 
  0.005 
   2639 
  24
  b = reshape(a,siz); 
  25 
else
  26 
  b = a;
  0.003 
   2639 
  27
end 

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