Changeset 273


Ignore:
Timestamp:
01/24/05 01:01:04 (19 years ago)
Author:
kil064
Message:

add arg. 'reftime' to function 'align'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/python/asapmath.py

    r271 r273  
    197197        return
    198198       
    199 def align(scan, insitu=None):
     199def align(scan, reftime=None, insitu=None):
    200200    """
    201201        Return a scan where all rows have been aligned in velocity. The
    202202        velocity reference frame (e.gh. LSRK), unit and doppler (e.g. OPTICAL)
    203         are those set by functions  set_unit and set_freqframe.  The data
    204         are aligned to the velocity abcissa at the first time present in the data.
    205         scan:        a scantable
    206         insitu:      if False a new scantable is returned.
    207                      Otherwise, the scaling is done in-situ
    208                      The default is taken from .asaprc (False)
    209     """
     203        are those set by functions  set_unit and set_freqframe. 
     204        scan:        a scantable
     205        reftime:     reference time to align at. By default, the time of
     206                     the first row of data is used. 
     207        insitu:      if False a new scantable is returned.
     208                     Otherwise, the scaling is done in-situ
     209                     The default is taken from .asaprc (False)
     210    """
     211    if reftime is None: reftime = ''
    210212    if insitu is None: insitu = rcParams['insitu']
    211213    if not insitu:
    212214        from asap._asap import align as _align
    213         return scantable(_align(scan))
     215        return scantable(_align(scan, reftime))
    214216    else:
    215217        from asap._asap import align_insitu as _align
    216         _align(scan)
     218        _align(scan, reftime)
    217219        return
    218220       
Note: See TracChangeset for help on using the changeset viewer.