This is a static copy of a profile report

Home

jet (Calls: 8, Time: 0.004 s)
Generated 16-Jul-2020 17:10:02 using performance time.
function in file /Applications/MATLAB_R2020a.app/toolbox/matlab/graphics/color/jet.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
hhsave_VFI_3OCfunction8
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
23
u = [(1:1:n)/n ones(1,n-1) (n:...
80.001 s27.0%
24
g = ceil(n/2) - (mod(m,4)==1) ...
80.000 s12.5%
33
J(b,3) = u(end-length(b)+1:end...
80.000 s9.1%
32
J(g,2) = u(1:length(g));
80.000 s8.7%
31
J(r,1) = u(1:length(r));
80.000 s6.9%
All other lines  0.001 s35.8%
Totals  0.004 s100% 
Children (called functions)
No children
Code Analyzer results
No Code Analyzer messages.
Coverage results
Show coverage for parent directory
Total lines in function33
Non-code lines (comments, blank lines)13
Code lines (lines that can run)20
Code lines that did run14
Code lines that did not run6
Coverage (did run/can run)70.00 %
Function listing
time 
Calls 
 line
   1 
function J = jet(m)
   2 
%JET    Variant of HSV
   3 
%   JET(M) returns an M-by-3 matrix containing the jet colormap, a variant
   4 
%   of HSV(M). The colors begin with dark blue, range through shades of
   5 
%   blue, cyan, green, yellow and red, and end with dark red. JET, by
   6 
%   itself, is the same length as the current figure's colormap. If no
   7 
%   figure exists, MATLAB uses the length of the default colormap.
   8 
%
   9 
%   See also PARULA, HSV, HOT, PINK, FLAG, COLORMAP, RGBPLOT.
  10 

  11 
%   Copyright 1984-2015 The MathWorks, Inc.
  12 

< 0.001 
      8 
  13
if nargin < 1 
  14 
   f = get(groot,'CurrentFigure');
  15 
   if isempty(f)
  16 
      m = size(get(groot,'DefaultFigureColormap'),1);
  17 
   else
  18 
      m = size(f.Colormap,1);
  19 
   end
< 0.001 
      8 
  20
end 
  21 

< 0.001 
      8 
  22
n = ceil(m/4); 
  0.001 
      8 
  23
u = [(1:1:n)/n ones(1,n-1) (n:-1:1)/n]'; 
< 0.001 
      8 
  24
g = ceil(n/2) - (mod(m,4)==1) + (1:length(u))'; 
< 0.001 
      8 
  25
r = g + n; 
< 0.001 
      8 
  26
b = g - n; 
< 0.001 
      8 
  27
g(g>m) = []; 
< 0.001 
      8 
  28
r(r>m) = []; 
< 0.001 
      8 
  29
b(b<1) = []; 
< 0.001 
      8 
  30
J = zeros(m,3); 
< 0.001 
      8 
  31
J(r,1) = u(1:length(r)); 
< 0.001 
      8 
  32
J(g,2) = u(1:length(g)); 
< 0.001 
      8 
  33
J(b,3) = u(end-length(b)+1:end); 

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