Changeset 316 for trunk/python


Ignore:
Timestamp:
01/28/05 02:09:40 (20 years ago)
Author:
kil064
Message:

add arg. 'weight' to function average_pol

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/python/asapmath.py

    r313 r316  
    286286        return
    287287
    288 def average_pol(scan, mask=None, insitu=None):
     288def average_pol(scan, mask=None, weight='none', insitu=None):
    289289    """
    290290    Average the Polarisations together.
     
    295295                     averaging will be applied. The output will have all
    296296                     specified points masked.
     297        weight:      Weighting scheme. 'none' (default), or 'var' (variance
     298                     weighted)
    297299        insitu:      if False a new scantable is returned.
    298300                     Otherwise, the scaling is done in-situ
     
    306308    if not insitu:
    307309        from asap._asap import averagepol as _avpol
    308         return scantable(_avpol(scan, mask))
     310        return scantable(_avpol(scan, mask, weight))
    309311    else:
    310312        from asap._asap import averagepol_insitu as _avpol
    311         _avpol(scan, mask)
     313        _avpol(scan, mask, weight)
    312314        return
    313315   
Note: See TracChangeset for help on using the changeset viewer.