This is a static copy of a profile report

Home

legendcolorbarlayout>localGetYLabelWidth (172 calls, 0.066 sec)
Generated 05-Aug-2011 13:02:35 using cpu time.
subfunction in file /usr/local/MATLAB/R2011a/toolbox/matlab/scribe/legendcolorbarlayout.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
legendcolorbarlayout>getPixelBoundssubfunction165
legendcolorbarlayout>doInOutLayoutsubfunction7
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
745
if ~isprop(yLab,'CachedPositio...
1700.055 s83.3%
750
pixBounds = get(yLab,'PixelBou...
1510.011 s16.7%
755
width = width(3);
1510 s0%
754
width = hgconvertunits(hFig,[0...
1510 s0%
753
hFig = ancestor(ax,'Figure');
1510 s0%
All other lines  0 s0%
Totals  0.066 s100% 
Children (called functions)

Function NameFunction TypeCallsTotal Time% TimeTime Plot
ispropfunction1700.033 s50.0%
is2Dfunction1720 s0%
Self time (built-ins, overhead, etc.)  0.033 s50.0%
Totals  0.066 s100% 
Code Analyzer results
No Code Analyzer messages.
Coverage results
[ Show coverage for parent directory ]
Total lines in function26
Non-code lines (comments, blank lines)8
Code lines (lines that can run)18
Code lines that did run13
Code lines that did not run5
Coverage (did run/can run)72.22 %
Function listing
   time   calls  line
730 function width = localGetYLabelWidth(ax,units)
731 % Returns the height (in the units specified) of an axes YLabel.
732
733 % If we are not a 2-D axes, return early
172 734 if ~is2D(ax)
735 width = 0;
736 return;
737 end
738
172 739 yLab = get(ax,'YLabel');
172 740 if isempty(get(yLab,'String'))
2 741 width = 0;
2 742 return;
743 end
744 % If the label is in "manual" mode, don't use it in computations:
0.05 170 745 if ~isprop(yLab,'CachedPosition') || ...
746 ~isequal(get(yLab,'CachedPosition'),get(yLab,'Position'))
19 747 width = 0;
19 748 return;
749 end
0.01 151 750 pixBounds = get(yLab,'PixelBounds');
751 % Add a small offset to keep things nice
151 752 leftChange = pixBounds(3) - pixBounds(1) + 10;
151 753 hFig = ancestor(ax,'Figure');
151 754 width = hgconvertunits(hFig,[0 0 leftChange 0],'Pixels',units,get(ax,'Parent'));
151 755 width = width(3);

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