Changeset 407
- Timestamp:
- 02/10/05 15:31:36 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/python/scantable.py
r402 r407 345 345 return retval 346 346 347 def get_time(self ):347 def get_time(self, row=-1): 348 348 """ 349 349 Get a list of time stamps for the observations. 350 350 Return a string for each integration in the scantable. 351 351 Parameters: 352 row: row no of integration. Default -1 return all rows 353 Example: 352 354 none 353 Example:354 none355 355 """ 356 356 out = [] 357 for i in range(self.nrow()): 358 out.append(self._gettime(i)) 359 return out 357 if row == -1: 358 for i in range(self.nrow()): 359 out.append(self._gettime(i)) 360 return out 361 else: 362 if row < self.nrow(): 363 return self._gettime(row) 360 364 361 365 def set_unit(self, unit='channel'): … … 378 382 Set the instrument for subsequent processing 379 383 Parameters: 380 instr: Select from "ATPKSMB", "ATPKSHOH", "ATMOPRA",381 "DSS-43" (Tid), "CEDUNA", and "HOBART"384 instr: Select from 'ATPKSMB', 'ATPKSHOH', 'ATMOPRA', 385 'DSS-43' (Tid), 'CEDUNA', and 'HOBART' 382 386 """ 383 387 self._setInstrument(instr) … … 433 437 first row, i.e. rowno=0 434 438 Returns: 435 The abcissa values and it's format string .439 The abcissa values and it's format string (as a dictionary) 436 440 """ 437 441 abc = self._getabcissa(rowno) 438 lbl = self._getabcissalabel(rowno) 442 lbl = self._getabcissalabel(rowno) 439 443 return abc, lbl 444 #return {'abcissa':abc,'label':lbl} 440 445 441 446 def create_mask(self, *args, **kwargs): … … 563 568 flags the spectrum for Beam=0, IF=0, Pol=1 564 569 """ 565 if (thebeam < self.nbeam() and theif < self.nif() and thepol < self.npol()): 566 stable.setbeam(thebeam) 567 stable.setif(theif) 568 stable.setpol(thepol) 569 stable._flag(self) 570 if (thebeam < self.nbeam() and 571 theif < self.nif() and 572 thepol < self.npol()): 573 sdtable.setbeam(self, thebeam) 574 sdtable.setif(self, theif) 575 sdtable.setpol(self, thepol) 576 sdtable._flag(self) 570 577 else: 571 578 print "Please specify a valid (Beam/IF/Pol)"
Note:
See TracChangeset
for help on using the changeset viewer.