Changeset 1145 for trunk/python
- Timestamp:
- 08/16/06 11:11:45 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/python/scantable.py
r1143 r1145 1021 1021 return s 1022 1022 1023 def average_beam(self, mask=None, weight='none'): 1024 """ 1025 Average the Beams together. 1026 Parameters: 1027 mask: An optional mask defining the region, where the 1028 averaging will be applied. The output will have all 1029 specified points masked. 1030 weight: Weighting scheme. 'none' (default), 'var' (1/var(spec) 1031 weighted), or 'tsys' (1/Tsys**2 weighted) 1032 """ 1033 varlist = vars() 1034 if mask is None: 1035 mask = () 1036 s = scantable(self._math._averagebeams(self, mask, weight.upper())) 1037 s._add_history("average_beam", varlist) 1038 print_log() 1039 return s 1040 1023 1041 def convert_pol(self, poltype=None): 1024 1042 """ … … 1331 1349 return s 1332 1350 1333 def mx_quotient(self, mask = None, weight='median' ):1351 def mx_quotient(self, mask = None, weight='median', preserve=True): 1334 1352 """ 1335 1353 Form a quotient using "off" beams when observing in "MX" mode. 1336 1354 Parameters: 1355 mask: an optional mask to be used when weight == 'stddev' 1337 1356 weight: How to average the off beams. Default is 'median'. 1357 preserve: you can preserve (default) the continuum or 1358 remove it. The equations used are 1359 preserve: Output = Toff * (on/off) - Toff 1360 remove: Output = Toff * (on/off) - Ton 1338 1361 """ 1339 1362 if mask is None: mask = () … … 1342 1365 preoff = scantable(self._math._mx_extract(self, 'off')) 1343 1366 off = preoff.average_time(mask=mask, weight=weight, scanav=False) 1344 print_log()1345 1367 from asapmath import quotient 1346 q = quotient(on, off )1368 q = quotient(on, off, preserve) 1347 1369 q._add_history("mx_quotient", varlist) 1370 print_log() 1348 1371 return q 1349 1372
Note:
See TracChangeset
for help on using the changeset viewer.