This is a static copy of a profile report

Home

graphics/private/name>fixTilde (40 calls, 0.000 sec)
Generated 05-Aug-2011 13:03:34 using cpu time.
subfunction in file /usr/local/MATLAB/R2011a/toolbox/matlab/graphics/private/name.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
graphics/private/namefunction40
Lines where the most time was spent
No measurable time spent in this function

Line NumberCodeCallsTotal Time% TimeTime Plot
155
end
400 s0%
138
if (fileName(1) == '~' &&a...
400 s0%
137
if (isunix && (length(...
400 s0%
135
filename = fileName;
400 s0%
134
persistent homeDir; % keep tra...
400 s0%
All other lines  0 s0%
Totals  0 s0% 
Children (called functions)

Function NameFunction TypeCallsTotal Time% TimeTime Plot
isunixfunction400 s0%
Self time (built-ins, overhead, etc.)  0 s0%
Totals  0 s0% 
Code Analyzer results
No Code Analyzer messages.
Coverage results
[ Show coverage for parent directory ]
Total lines in function23
Non-code lines (comments, blank lines)8
Code lines (lines that can run)15
Code lines that did run5
Code lines that did not run10
Coverage (did run/can run)33.33 %
Function listing
   time   calls  line
133 function filename = fixTilde(fileName)
40 134 persistent homeDir; % keep track of user's home dir
40 135 filename = fileName;
136 % yes, we tested for isunix above...but in case that test gets deleted
40 137 if (isunix && (length(fileName) > 1))
40 138 if (fileName(1) == '~' && fileName(2) == filesep)
139 if isempty(homeDir)
140 % save current location,
141 % go 'home' and remember that location
142 % switch back to original location
143 currDir = pwd;
144 cd('~');
145 homeDir = pwd;
146 cd(currDir);
147 end
148 if ~isempty(homeDir)
149 % now that we know where the home dir is
150 % replace 1st char (~) with user's home dir and take rest of
151 % path specified
152 filename = [homeDir fileName(2:end)];
153 end
154 end
40 155 end

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