This is a static copy of a profile reportHome
gca (454 calls, 0.250 sec)
Generated 15-Mar-2007 12:01:45 using real time.
M-function in file C:\Program Files\MATLAB71\toolbox\matlab\graphics\gca.m
[Copy to new window for comparing multiple runs]
Parents (calling functions)
Function Name | Function Type | Calls |
title | M-function | 17 |
newplot | M-function | 46 |
hold | M-function | 279 |
axis | M-function | 112 |
Lines where the most time was spent
Line Number | Code | Calls | Total Time | % Time | Time Plot |
21 | h = get(fig,'CurrentAxes'); | 454 | 0.125 s | 50.0% |  |
18 | fig = gcf; | 408 | 0.063 s | 25.0% |  |
27 | h = axes('parent',fig); | 41 | 0.016 s | 6.3% |  |
26 | if isempty(h) | 454 | 0.016 s | 6.3% |  |
28 | end | 41 | 0 s | 0% |  |
Other lines & overhead | | | 0.031 s | 12.5% |  |
Totals | | | 0.250 s | 100% | |
Children (called functions)
Function Name | Function Type | Calls | Total Time | % Time | Time Plot |
gcf | M-function | 408 | 0.063 s | 25.0% |  |
Self time (built-ins, overhead, etc.) | | | 0.188 s | 75.0% |  |
Totals | | | 0.250 s | 100% | |
M-Lint results
No M-Lint messages.Coverage results
[ Show coverage for parent directory ]
Total lines in file | 28 |
Non-code lines (comments, blank lines) | 21 |
Code lines (lines that can run) | 7 |
Code lines that did run | 7 |
Code lines that did not run | 0 |
Coverage (did run/can run) | 100.00 % |
Function listing
time calls line
1 function h = gca(fig)
2 %GCA Get handle to current axis.
3 % H = GCA returns the handle to the current axis in the current
4 % figure. The current axis is the axis that graphics commands
5 % like PLOT, TITLE, SURF, etc. draw to if issued.
6 % Use the commands AXES or SUBPLOT to change the current axis
7 % to a different axis, or to create new ones.
8 %
9 % See also AXES, SUBPLOT, DELETE, CLA, HOLD, GCF, GCBO, GCO, GCBF.
10
11 % H = GCA(FIG) returns the handle to the current axis in the
12 % specified figure (it need not be the current figure).
13 %
14 % Copyright 1984-2002 The MathWorks, Inc.
15 % $Revision: 5.18 $ $Date: 2002/04/10 17:07:11 $
16
454 17 if nargin == 0
0.06 408 18 fig = gcf;
408 19 end
20
0.13 454 21 h = get(fig,'CurrentAxes');
22
23 % 'CurrentAxes' is no longer guaranteed to return an axes,
24 % so we might need to create one (because gca IS guaranteed to
25 % return an axes)
0.02 454 26 if isempty(h)
0.02 41 27 h = axes('parent',fig);
41 28 end