This is a static copy of a profile reportHome
xlabel (460 calls, 0.634 sec)
Generated 05-Aug-2011 13:03:26 using cpu time.
function in file /usr/local/MATLAB/R2011a/toolbox/matlab/graph2d/xlabel.m
Copy to new window for comparing multiple runs
Parents (calling functions)
Lines where the most time was spent
Line Number | Code | Calls | Total Time | % Time | Time Plot |
40 | h = get(ax,'XLabel'); | 230 | 0.481 s | 75.9% |  |
45 | set(h, 'FontAngle', get(ax, '... | 230 | 0.055 s | 8.6% |  |
19 | [ax,args,nargs] = axescheck(va... | 460 | 0.044 s | 6.9% |  |
58 | set(h, 'String', string, pvpai... | 230 | 0.011 s | 1.7% |  |
42 | if feature('hgUsingMATLABClass... | 230 | 0.011 s | 1.7% |  |
All other lines | | | 0.033 s | 5.2% |  |
Totals | | | 0.634 s | 100% | |
Children (called functions)
Function Name | Function Type | Calls | Total Time | % Time | Time Plot |
axescheck | function | 460 | 0.033 s | 5.2% |  |
xlabel | function | 230 | 0 s | 0% |  |
gcf | function | 230 | 0 s | 0% |  |
Self time (built-ins, overhead, etc.) | | | 0.601 s | 94.8% |  |
Totals | | | 0.634 s | 100% | |
Code Analyzer results
No Code Analyzer messages.Coverage results
[ Show coverage for parent directory ]
Total lines in function | 64 |
Non-code lines (comments, blank lines) | 37 |
Code lines (lines that can run) | 27 |
Code lines that did run | 20 |
Code lines that did not run | 7 |
Coverage (did run/can run) | 74.07 % |
Function listing
time calls line
1 function hh = xlabel(varargin)
2 %XLABEL X-axis label.
3 % XLABEL('text') adds text beside the X-axis on the current axis.
4 %
5 % XLABEL('text','Property1',PropertyValue1,'Property2',PropertyValue2,...)
6 % sets the values of the specified properties of the xlabel.
7 %
8 % XLABEL(AX,...) adds the xlabel to the specified axes.
9 %
10 % H = XLABEL(...) returns the handle to the text object used as the label.
11 %
12 % See also YLABEL, ZLABEL, TITLE, TEXT.
13
14 % Copyright 1984-2010 The MathWorks, Inc.
15 % $Revision: 5.13.6.12 $ $Date: 2010/05/20 02:25:32 $
16
0.01 460 17 error(nargchk(1,inf,nargin,'struct'));
18
0.04 460 19 [ax,args,nargs] = axescheck(varargin{:});
460 20 if isempty(ax)
21 % call xlabel recursively or call method of Axes subclass
0.01 230 22 h = xlabel(gca,varargin{:});
230 23 if nargout > 0, hh = h; end
230 24 return;
25 end
26
230 27 if nargs > 1 && (rem(nargs-1,2) ~= 0)
28 error('MATLAB:xlabel:InvalidNumberOfInputs','Incorrect number of input arguments')
29 end
30
230 31 string = args{1};
230 32 if isempty(string), string=''; end;
230 33 pvpairs = args(2:end);
34
230 35 if isappdata(ax,'MWBYPASS_xlabel')
36 h = mwbypass(ax,'MWBYPASS_xlabel',string,pvpairs{:});
37
38 %---Standard behavior
230 39 else
0.48 230 40 h = get(ax,'XLabel');
41
0.01 230 42 if feature('hgUsingMATLABClasses') == 0
43 %Over-ride text objects default font attributes with
44 %the Axes' default font attributes.
0.05 230 45 set(h, 'FontAngle', get(ax, 'FontAngle'), ...
46 'FontName', get(ax, 'FontName'), ...
47 'FontUnits', get(ax, 'FontUnits'),...
48 'FontSize', get(ax, 'FontSize'), ...
49 'FontWeight', get(ax, 'FontWeight'));
50 else
51 set(h,'FontAngleMode','auto',...
52 'FontNameMode','auto',...
53 'FontUnitsMode','auto',...
54 'FontSizeMode','auto',...
55 'FontWeightMode','auto');
56 end
57
0.01 230 58 set(h, 'String', string, pvpairs{:});
59
230 60 end
61
230 62 if nargout > 0
230 63 hh = h;
230 64 end