This is a static copy of a profile reportHome
noiseWrapper (1 call, 0.426 sec)
Generated 05-Aug-2011 13:01:17 using cpu time.
function in file /home/LeechJ/cbass_analysis/reduc/support/noiseWrapper.m
Copy to new window for comparing multiple runs
Parents (calling functions)
Function Name | Function Type | Calls |
reduceData | function | 1 |
Lines where the most time was spent
Line Number | Code | Calls | Total Time | % Time | Time Plot |
39 | [d flags] = packd(d, flags, 'n... | 1 | 0.350 s | 82.1% |  |
35 | setPlotDisplay(plotparams.plot... | 1 | 0.066 s | 15.4% |  |
15 | if(~issubfield(d, 'correction'... | 1 | 0.011 s | 2.6% |  |
68 | return; | 1 | 0 s | 0% |  |
61 | end | 1 | 0 s | 0% |  |
All other lines | | | 0 s | 0% |  |
Totals | | | 0.426 s | 100% | |
Children (called functions)
Function Name | Function Type | Calls | Total Time | % Time | Time Plot |
packd | function | 1 | 0.350 s | 82.1% |  |
setPlotDisplay | function | 1 | 0.066 s | 15.4% |  |
checkpar | function | 1 | 0 s | 0% |  |
where_am_i | function | 1 | 0 s | 0% |  |
issubfield | function | 1 | 0 s | 0% |  |
Self time (built-ins, overhead, etc.) | | | 0.011 s | 2.6% |  |
Totals | | | 0.426 s | 100% | |
Code Analyzer results
Line number | Message |
1 | Extra semicolon is unnecessary. |
54 | Use && instead of & as the AND operator in (scalar) conditional statements. |
54 | Use && instead of & as the AND operator in (scalar) conditional statements. |
57 | The value assigned to variable 'allNoise' might be unused. |
Coverage results
[ Show coverage for parent directory ]
Total lines in function | 68 |
Non-code lines (comments, blank lines) | 35 |
Code lines (lines that can run) | 33 |
Code lines that did run | 17 |
Code lines that did not run | 16 |
Coverage (did run/can run) | 51.52 % |
Function listing
time calls line
1 function d = noiseWrapper(d, plotparams, parm, field);
2
3 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
4 %
5 % function d = noiseWrapper(d, plotparams, parm, field);
6 %
7 % reduceData function that calls functions to calculate noise
8 %
9 % sjcm
10 %
11 % 3/30/2011 sjcm: saving plots without display
12 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
13
14 % by this point, we should already have the system temperature values.
0.01 1 15 if(~issubfield(d, 'correction', 'tsys'))
16 display('Fail: system temperatures not present');
17 display('Run calcTsys first');
18 return;
19 end
20
1 21 if(size(d.antenna0.receiver.data,2)==8)
22 display('HA! you think you can get noise temps without tsys? try again');
23 return;
24 end
25
26
27 % check to see if there are any values.
1 28 if(isempty(d.correction.tsys.val))
29 d.correction.tsys.val = [];
30 display('No Noise temperature measurements in this track');
31 display('Will use latest values in the archive');
32 return;
33 end
34
0.07 1 35 setPlotDisplay(plotparams.plot);
36 % all flagging has already happened in the tsys step, so we just plot.
1 37 display('Plotting data');
1 38 flags = d.correction.tsys.flag;
0.35 1 39 [d flags] = packd(d, flags, 'none', 'noise', plotparams, 'Noise Diode Temperature Plots', field);
1 40 d.correction.tsys.flag = flags;
41
42
43 % next we write things to disk
1 44 thisNoise = d.correction.tsys.tnoise;
1 45 thisNoise(d.correction.tsys.flag>0) = nan;
1 46 thisNoise = [d.correction.tsys.time d.correction.tsys.source thisNoise];
47
1 48 [home,installeddir]=where_am_i();
49
50
51 % make sure file is up-to-date
1 52 parFlag = checkpar(parm, 'autosave');
1 53 if(parFlag)
1 54 if(parm.autosave.flag & d.correction.survey==0 & d.correction.tsys.allbad==0)
55 %system('cvs update constants/noise_diode_values.txt');
56 allNoise = load([home,'/',installeddir,'/constants/noise_diode_values.txt']);
57 allNoise = [allNoise; thisNoise];
58 save([home,'/',installeddir,'/constants/noise_diode_values.txt'], 'allNoise', '-ascii', '-single')
59 %system('cvs commit -m "update" constants/noise_diode_values.txt');
60 end
1 61 end
62
63
64
65
66
67
1 68 return;
Other subfunctions in this file are not included in this listing.