casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables
Public Member Functions | Public Attributes | Static Private Attributes
__casac__.ms.ms Class Reference
Inheritance diagram for __casac__.ms.ms:
__casac__.ms._object

List of all members.

Public Member Functions

def __init__
def fromfits
def fromfitsidi
def listfits
def createmultims
def ismultims
def getreferencedtables
def nrow
def iswritable
def open
def reset
def close
def name
def tofits
def summary
def getscansummary
def getspectralwindowinfo
def listhistory
def writehistory
def statistics
def range
def lister
def metadata
def selectinit
def msselect
def msselectedindices
def select
def selecttaql
def selectchannel
def selectpolarization
def regridspw
def cvel
def cvelfreqs
def getdata
def putdata
def concatenate
def testconcatenate
def virtconcatenate
def timesort
def contsub
def statwt
def split
def partition
def iterinit
def iterorigin
def iternext
def iterend
def fillbuffer
def diffbuffer
def getbuffer
def clipbuffer
def setbufferflags
def writebufferflags
def clearbuffer
def continuumsub
def done
def msseltoindex
def hanningsmooth
def uvsub
def moments

Public Attributes

 this

Static Private Attributes

dictionary __swig_setmethods__
tuple __setattr__
dictionary __swig_getmethods__
tuple __getattr__
 __repr__
 __swig_destroy__
 __del__

Detailed Description

Proxy of C++ casac::ms class

Definition at line 70 of file ms.py.


Constructor & Destructor Documentation

def __casac__.ms.ms.__init__ (   self)
__init__(self) -> ms

Definition at line 77 of file ms.py.


Member Function Documentation

clearbuffer(self) -> bool

Summary
Clear the internal buffer.
--------------------------------------------------------------------------------

Definition at line 1035 of file ms.py.

def __casac__.ms.ms.clipbuffer (   self,
  pixellevel = 0.0,
  timelevel = 0.0,
  channellevel = 0.0 
)
clipbuffer(self, pixellevel=0.0, timelevel=0.0, channellevel=0.0) -> bool

Summary
(NON-FUNCTIONAL???) Clip the internal buffer with specified limits.

Input Parameters:
pixellevel       cliplevel for pixels (greater than 0) 0.0 
timelevel        cliplevel for time slots (greater than 0) 0.0 
channellevel     cliplevel for channels (greater than 0) 0.0 

--------------------------------------------------------------------------------

Definition at line 992 of file ms.py.

def __casac__.ms.ms.close (   self)
close(self) -> bool

Summary
Detach the ms tool from the measurement set table
--------------------------------------------------------------------------------

Definition at line 244 of file ms.py.

def __casac__.ms.ms.concatenate (   self,
  args,
  kwargs 
)
concatenate(self, msfile=string(""), freqtol=initialize_variant("1Hz"), dirtol=initialize_variant("1mas"), 
    weightscale=1., handling=0, destmsfile=string(""), respectname=False) -> bool

Summary
Concatenate two measurement sets

Input Parameters:
msfile           The name of the measurement set to append 
freqtol          Frequency difference within which 2 spectral windows are considered similar; e.g '10Hz' 1Hz 
dirtol           Direction difference within which 2 fields are considered the same; e.g '1mas' 1mas 
weightscale      Scale the weights of the MS to be appended by this factor 1. 
handling         Switch for the handling of the Main and Pointing tables: 0=standard, 1=no Main, 2=no Pointing, 3=no Main and Pointing, 4=virtual 0 0 1 2 3 
destmsfile       Optional support for virtual concat: empty table (no subtables) where to store the appended MS copy 
respectname      If true, fields with a different name are not merged even if their direction agrees false 

--------------------------------------------------------------------------------

Definition at line 686 of file ms.py.

def __casac__.ms.ms.continuumsub (   self,
  args,
  kwargs 
)
continuumsub(self, field=initialize_variant(""), fitspw=initialize_variant(""), spw=initialize_variant(""), 
    solint=initialize_variant("int"), fitorder=0, mode=string("subtract")) -> bool

Summary
Continuum fitting and subtraction in uv plane

Input Parameters:
field            Select fields to fit 
fitspw           Spectral windows/channels to use for fitting the continuum; default all spectral windows in all channels 
spw              Select spectral windows and channels from which to subtract a continuum estimate; default: all channels in all spectral windows for which the continuum was estimated 
solint           Continuum fit timescale (units optional) int 
fitorder         Polynomial order for fit 0 
mode             Desired use of fit model (see below) subtract 

--------------------------------------------------------------------------------

Definition at line 1046 of file ms.py.

def __casac__.ms.ms.contsub (   self,
  args,
  kwargs 
)
contsub(self, outputms=string(""), fitspw=initialize_variant("*"), fitorder=1, combine=string(""), 
    spw=initialize_variant("*"), unionspw=initialize_variant("*"), field=initialize_variant(""), 
    scan=initialize_variant(""), intent=string(""), correlation=string(""), 
    obs=string(""), whichcol=string("CORRECTED_DATA")) -> bool

Summary
Subtract the continuum from the visibilities

Input Parameters:
outputms         The name of the resulting measurement set 
fitspw           Line-free spectral windows (and :channels) to fit to * 
fitorder         The order of the polynomial to use when fitting. 1 
combine          Ignore changes in these columns (spw, scan, and/or state) when fitting. 
spw              Spectral windows (and :channels) to select * 
unionspw         The union of fitspw and spw, i.e. how much needs to be read. '*' always works, but may be more than you need. * 
field            Fields to include, by names or 0-based ids. ('' => all) 
scan             Only use the scan numbers requested using the msselection syntax. 
intent           Only use the requested scan intents. 
correlation      Limit data to specific correlations (LL, XX, LR, XY, etc.). 
obs              Only use the requested observation IDs. 
whichcol         'DATA', 'MODEL_DATA', 'CORRECTED_DATA', and/or 'FLOAT_DATA' CORRECTED_DATA 

--------------------------------------------------------------------------------

Definition at line 763 of file ms.py.

def __casac__.ms.ms.createmultims (   self,
  args,
  kwargs 
)
createmultims(self, outputTableName, tables, subtables, nomodify=True, lock=False, copysubtables=False, 
    omitsubtables=std::vector< string >(1, "")) -> bool

Summary



Input Parameters:
outputTableName 
tables          
subtables       
nomodify         prevent changes to the measurement set true 
lock             lock the table for exclusive use by this tool false 
copysubtables    copy the subtables from the first to all other member MSs false 
omitsubtables    Omit the subtables from this list when copying subtables 

--------------------------------------------------------------------------------

Definition at line 142 of file ms.py.

def __casac__.ms.ms.cvel (   self,
  args,
  kwargs 
)
cvel(self, mode=string("channel"), nchan=-1, start=initialize_variant("0"), width=initialize_variant("1"), 
    interp=string("linear"), phasec=initialize_variant(""), restfreq=initialize_variant("1.4GHz"), 
    outframe=string(""), veltype=string("radio"), 
    hanning=True) -> bool

Summary
transform spectral data to different reference frame and/or regrid the frequency channels
   

Input Parameters:
mode             'channel', 'velocity', 'frequency', or 'channel_b', default = 'channel' channel 
nchan            number of channels, default = -1 = all -1 
start            start channel, default = 0 0 
width            new channel width, default = 1 1 
interp           interpolation method 'nearest', 'linear', 'spline', 'cubic', 'fftshift', default = linear linear 
phasec           phase center, default = first field 
restfreq         rest frequency, default = 1.4GHz 1.4GHz 
outframe         LSRK, LSRD, BARY, GALACTO, LGROUP, CMB, GEO, or TOPO, default = '' = keep reference frame. 
veltype          radio or optical, default = radio radio 
hanning          If true, perform hanning smoothing before regridding. true 

--------------------------------------------------------------------------------

Definition at line 595 of file ms.py.

def __casac__.ms.ms.cvelfreqs (   self,
  args,
  kwargs 
)
cvelfreqs(self, spwids=initialize_vector(1, (int)0), fieldids=initialize_vector(1, (int)0), obstime=string(""), 
    mode=string("channel"), nchan=-1, start=initialize_variant("0"), 
    width=initialize_variant("1"), phasec=initialize_variant("0"), restfreq=initialize_variant("1.4GHz"), 
    outframe=string(""), veltype=string("radio")) -> std::vector< double >

Summary
calculate the transformed grid of the SPW obtained by combining a given set of SPWs (MS is not modified)
   

Input Parameters:
spwids           The list of ids of the spectral windows from which the input grid is to be taken. 0 
fieldids         The list of ids of the fields which are selected (for observation time determination), default: all 0 
obstime          the observation time to assume, default: time of the first row of the MS = 
mode             'channel', 'velocity', 'frequency', or 'channel_b', default = channel 
nchan            number of channels, default = all = -1 
start            start channel, default = 0 
width            new channel width, default = 1 
phasec           phase center, default = first field = 0 
restfreq         rest frequency, default = 1.4GHz 
outframe         LSRK, LSRD, BARY, GALACTO, LGROUP, CMB, GEO, or TOPO, default = keep reference frame = 
veltype          radio or optical, default = radio 

--------------------------------------------------------------------------------

Definition at line 623 of file ms.py.

def __casac__.ms.ms.diffbuffer (   self,
  args,
  kwargs 
)
diffbuffer(self, direction=string("TIME"), window=1) -> record *

Summary
Differentiate or difference the internal buffer.

Input Parameters:
direction        choose between time or channel direction: TIME or CHANNEL TIME 
window           width of averaging window in timeslots or channels; integer greater than 0 1 

--------------------------------------------------------------------------------

Definition at line 965 of file ms.py.

def __casac__.ms.ms.done (   self)
done(self) -> bool

Summary
Closes the ms tool
--------------------------------------------------------------------------------

Definition at line 1067 of file ms.py.

def __casac__.ms.ms.fillbuffer (   self,
  args,
  kwargs 
)
fillbuffer(self, item=string(""), ifraxis=False) -> bool

Summary
Fill the internal buffer with data and flags.

Input Parameters:
item             data derived item 
ifraxis          Create interferometer axis if True false 

--------------------------------------------------------------------------------

Definition at line 949 of file ms.py.

def __casac__.ms.ms.fromfits (   self,
  args,
  kwargs 
)
fromfits(self, msfile=string(""), fitsfile=string(""), nomodify=True, lock=False, obstype=0, host=string(""), 
    forcenewserver=False, antnamescheme=string("old")) -> bool

Summary
Create a measurement set from a uvfits file

Input Parameters:
msfile           Filename for the newly created measurement set 
fitsfile         uvfits file to read 
nomodify         open for read access only true 
lock             lock the table for exclusive use false 
obstype          specify the observation type: 0=standard, 1=fastmosaic, requiring small tiles in the measurement set 0 
host             host to start ms tool on (IGNORED!!!) 
forcenewserver   start a new server tool (IGNORED!!!) false 
antnamescheme    For VLA only, antenna name scheme, old style is just antenna number, new style prepends VA or EV old old new 

--------------------------------------------------------------------------------

Definition at line 84 of file ms.py.

def __casac__.ms.ms.fromfitsidi (   self,
  args,
  kwargs 
)
fromfitsidi(self, msfile=string(""), fitsfile=string(""), nomodify=True, lock=False, obstype=0) -> bool

Summary
Create a measurement set from a fits-idi file

Input Parameters:
msfile           Filename for the newly created measurement set 
fitsfile         fits-idi file to read 
nomodify         open for read access only true 
lock             lock the table for exclusive use false 
obstype          specify the observation type: 0=standard, 1=fastmosaic, requiring small tiles in the measurement set 0 

--------------------------------------------------------------------------------

Definition at line 107 of file ms.py.

def __casac__.ms.ms.getbuffer (   self)
getbuffer(self) -> record *

Summary
Return the internal buffer as a Record for access from the intrepreter.
--------------------------------------------------------------------------------

Definition at line 981 of file ms.py.

def __casac__.ms.ms.getdata (   self,
  args,
  kwargs 
)
getdata(self, items=std::vector< string >(1, ""), ifraxis=False, ifraxisgap=0, increment=1, average=False) -> record *

Summary
Read values from the measurement set.

Input Parameters:
items            Item names 
ifraxis          Create interferometer axis if True false 
ifraxisgap       Gap size on ifr axis when antenna1 changes 0 
increment        Row increment for data access 1 
average          Average the data in time or over rows false 

--------------------------------------------------------------------------------

Definition at line 652 of file ms.py.

Referenced by tests.test_sdgrid.sdgrid_flagging._testresult(), tests.test_sdgrid.sdgrid_single_integ.test100(), tests.test_sdgrid.sdgrid_single_integ.test101(), tests.test_sdgrid.sdgrid_single_integ.test102(), tests.test_sdgrid.sdgrid_single_integ.test103(), tests.test_sdgrid.sdgrid_clipping.test200(), tests.test_sdgrid.sdgrid_weighting.test400(), tests.test_sdgrid.sdgrid_weighting.test401(), tests.test_sdgrid.sdgrid_weighting.test402(), tests.test_sdgrid.sdgrid_weighting.test403(), tests.test_sdgrid.sdgrid_map.test500(), tests.test_sdgrid.sdgrid_map.test501(), tests.test_sdgrid.sdgrid_map.test502(), tests.test_sdgrid.sdgrid_map.test503(), and tests.test_sdgrid.sdgrid_grid_center.test700().

getreferencedtables(self) -> std::vector< std::string >

Summary


--------------------------------------------------------------------------------

Definition at line 177 of file ms.py.

getscansummary(self) -> record *

Summary
Get the summary of the ms
--------------------------------------------------------------------------------

Definition at line 315 of file ms.py.

getspectralwindowinfo(self) -> record *

Summary
Get a summary of the spectral windows
--------------------------------------------------------------------------------

Definition at line 326 of file ms.py.

def __casac__.ms.ms.hanningsmooth (   self,
  args,
  kwargs 
)
hanningsmooth(self, datacolumn=string("corrected")) -> bool

Summary
Hanning smooth the frequency channels to remove Gibbs ringing.

Input Parameters:
datacolumn       the name of the MS column into which to write the smoothed data corrected 

--------------------------------------------------------------------------------

Definition at line 1104 of file ms.py.

def __casac__.ms.ms.ismultims (   self)
ismultims(self) -> bool

Summary


--------------------------------------------------------------------------------

Definition at line 165 of file ms.py.

iswritable(self) -> bool

Summary
Returns True is the underlying Table is
  writable
--------------------------------------------------------------------------------

Definition at line 204 of file ms.py.

def __casac__.ms.ms.iterend (   self)
iterend(self) -> bool

Summary
End the iteration and reset the selected table
--------------------------------------------------------------------------------

Definition at line 938 of file ms.py.

def __casac__.ms.ms.iterinit (   self,
  args,
  kwargs 
)
iterinit(self, columns=std::vector< string >(1, ""), interval=0.0, maxrows=0, adddefaultsortcolumns=True) -> bool

Summary
Initialize for iteration over an ms

Input Parameters:
columns          Vector of column names (case sensitive). 
interval         Time interval in seconds (greater than 0), to group together in iteration 0.0 
maxrows          Max number of rows (greater than 0) to return in iteration 0 
adddefaultsortcolumns    Add the default sort columns true 

--------------------------------------------------------------------------------

Definition at line 898 of file ms.py.

def __casac__.ms.ms.iternext (   self)
iternext(self) -> bool

Summary
Advance the iterator to the next lot of data
--------------------------------------------------------------------------------

Definition at line 927 of file ms.py.

iterorigin(self) -> bool

Summary
Set the iterator to the start of the data.
--------------------------------------------------------------------------------

Definition at line 916 of file ms.py.

def __casac__.ms.ms.lister (   self,
  args,
  kwargs 
)
lister(self, options=string(""), datacolumn=string("data"), field=string(""), spw=string(""), 
    antenna=string(""), timerange=string(""), correlation=string(""), scan=string(""), 
    feed=string(""), array=string(""), observation=string(""), uvrange=string(""), 
    average=string(""), showflags=False, msselect=string(""), pagerows=50, 
    listfile=string("")) -> bool

Summary
List measurement set visibilities

Input Parameters:
options          Output options (not yet implemented) 
datacolumn       Column to list: data, model, corrected, residual data 
field            Fields 
spw              Spectral Windows 
antenna          Antenna/Baselines 
timerange        Time range 
correlation      Polarization correlations 
scan             Scan 
feed             Feed (not yet implemented) 
array            Array 
observation      Select by observation ID(s) 
uvrange          uv-distance (output units: wavelength) 
average          Average mode (not yet implemented) 
showflags        Showflags (not yet implemented) false 
msselect         TaQL expression 
pagerows         Rows per page 50 
listfile         Output file 

--------------------------------------------------------------------------------

Definition at line 413 of file ms.py.

def __casac__.ms.ms.listfits (   self,
  args,
  kwargs 
)
listfits(self, fitsfile) -> bool

Summary



Input Parameters:
fitsfile         list HDU and typical data rows in a fits file 

--------------------------------------------------------------------------------

Definition at line 126 of file ms.py.

listhistory(self) -> bool

Summary
List history of the measurement set
--------------------------------------------------------------------------------

Definition at line 337 of file ms.py.

def __casac__.ms.ms.metadata (   self)
metadata(self) -> casac::msmetadata *

Summary
Get the MS metadata associated with this MS.
--------------------------------------------------------------------------------

Definition at line 448 of file ms.py.

def __casac__.ms.ms.moments (   self,
  args,
  kwargs 
)
moments(self, moments=initialize_vector(1, (int)0), antenna=initialize_variant(""), field=initialize_variant(""), 
    spw=initialize_variant(""), includemask=initialize_vector(1, (double)-1), 
    excludemask=initialize_vector(1, (double)-1), peaksnr=0.0, 
    stddev=0.0, doppler=string(""), outfile=string(""), overwrite=False, async=False) -> casac::table *

Summary
Calculate moments from MS with FLOAT_DATA column.

Input Parameters:
moments          A list of moments that you want to compute. Default is an integrarted spectrum. 0 
antenna          antenna name or id 
field            field name or id 
spw              spectral window id 
includemask      A range of masks to be included when moments are computed. Default is -1 (all channels). -1 
excludemask      A range of masks to be excluded when moments are computed. Default is -1 (do not exclude channels). -1 
peaksnr          The SNR ratio that is a lower limit to be included a moment calculation (not implemented yet). 0.0 
stddev           Standard deviation of the noise signal in the spectra (used by the window and fit functions only). 0.0 
doppler          Velocity doppler definition for velocity computations along spectral axes. 
outfile          Output MS file name (or root for multiple moments). Default is input + an auto-determined suffix. 
overwrite        Overwrite existing output file. false 
async            Run asynchronously? false 

--------------------------------------------------------------------------------

Definition at line 1134 of file ms.py.

def __casac__.ms.ms.msselect (   self,
  args,
  kwargs 
)
msselect(self, items=initialize_record(""), onlyparse=False) -> bool

Summary
Use the MSSelection module for data selection.

Input Parameters:
items            Record with fields contain the selection experessions. Keys recognized in the record are: 'spw', 'time', 'field', 'baseline', 'scan', 'scanintent', 'polarization', 'observation', 'array', 'uvdist' and 'taql'. 
onlyparse        If set to True, expressions will only be parsed but not applied to the MS for selection. When set to False, a selected MS will also be generated internally. Default is False. When only parsing is requested, the selected-MS is the same as the original MS. false 

--------------------------------------------------------------------------------

Definition at line 475 of file ms.py.

msselectedindices(self) -> record *

Summary

       Return the selected indices of the MS database.  The keys in
       the record are the same as those used in msselect function
       (i.e. 'spw', 'time', 'field', 'baseline', 'scan', 'scanintent',
       'polarization' and 'uvdist').
     
--------------------------------------------------------------------------------

Definition at line 491 of file ms.py.

def __casac__.ms.ms.msseltoindex (   self,
  args,
  kwargs 
)
msseltoindex(self, vis=string(""), spw=initialize_variant(""), field=initialize_variant(""), baseline=initialize_variant(""), 
    time=initialize_variant(""), scan=initialize_variant(""), 
    uvrange=initialize_variant(""), observation=initialize_variant(""), 
    taql=string("")) -> record *

Summary
Returns ids of the selection used

Input Parameters:
vis              Measurementset for which this selection applies 
spw              Spectral Window Ids (0 relative) to select; -1 interpreted as all 
field            Field Ids (0 relative) or Field names (msselection syntax and wilcards are used) to select 
baseline         Antenna Ids (0 relative) or Antenna names (msselection syntax and wilcards are used) to select 
time             Limit data selected to be within a given time range. Syntax is the defined in the msselection link 
scan             Limit data selected on scan numbers. Syntax is the defined in the msselection link 
uvrange          Limit data selected on uv distance. Syntax is the defined in the msselection link 
observation      Select data by observation ID(s). The syntax is the same as for scan numbers. 
taql             For the TAQL experts, flexible data selection using the TAQL syntax 

--------------------------------------------------------------------------------

Definition at line 1078 of file ms.py.

def __casac__.ms.ms.name (   self)
name(self) -> string

Summary
Name of the measurement set table the tool is attached to.
--------------------------------------------------------------------------------

Definition at line 255 of file ms.py.

def __casac__.ms.ms.nrow (   self,
  selected = False 
)
def __casac__.ms.ms.open (   self,
  args,
  kwargs 
)
open(self, thems=string(""), nomodify=True, lock=False) -> bool

Summary
Attach the ms tool to a measurement set table

Input Parameters:
thems            Name of the measurement set table to open 
nomodify         prevent changes to the measurement set true 
lock             lock the table for exclusive use by this tool false 

--------------------------------------------------------------------------------

Definition at line 216 of file ms.py.

def __casac__.ms.ms.partition (   self,
  args,
  kwargs 
)
partition(self, outputms=string(""), field=initialize_variant(""), spw=initialize_variant("*"), baseline=initialize_variant(""), 
    timebin=initialize_variant("-1s"), time=string(""), 
    scan=initialize_variant(""), uvrange=initialize_variant(""), taql=string(""), 
    whichcol=string("DATA"), tileshape=initialize_variant(""), subarray=initialize_variant(""), 
    combine=string(""), intent=string(""), obs=string("")) -> bool

Summary
make a new ms from a subset of an existing ms, without changing any subtables

Input Parameters:
outputms         The name of the resulting measurement set 
field            Fields to include, by names or 0-based ids. ('' => all) 
spw              Spectral windows (and :channels) to select * 
baseline         Antenna names or indices to select ('' => all) 
timebin          Duration for averaging. Defaults to no averaging. -1s 
time             Only use data in the given time range, using the msselection syntax. 
scan             Only use the scan numbers requested using the msselection syntax. 
uvrange          Limit data by uv distance using the msselection syntax. 
taql             For the TAQL experts, flexible data selection using the TAQL syntax 
whichcol         'DATA', 'MODEL_DATA', 'CORRECTED_DATA', 'FLOAT_DATA', 'LAG_DATA', and/or 'all' DATA 
tileshape        Tile shape of the disk data columns, most users should not need to touch this parameter [0] => normal tiling, [1] => fast mosaic style tile [4,15,351] => a tile shape of 4 pol 15 chan and 351 rows 
subarray         Limit data to specific (sub)array numbers. 
combine          Ignore changes in these columns (scan, and/or state) when time averaging. 
intent           Only use the requested scan intents. 
obs              Only use the requested observation IDs. 

--------------------------------------------------------------------------------

Definition at line 865 of file ms.py.

def __casac__.ms.ms.putdata (   self,
  args,
  kwargs 
)
putdata(self, items=initialize_record("")) -> bool

Summary
Write new values into the measurement set

Input Parameters:
items            Record with items and their new values 

--------------------------------------------------------------------------------

Definition at line 671 of file ms.py.

def __casac__.ms.ms.range (   self,
  args,
  kwargs 
)
range(self, items=std::vector< string >(1, ""), useflags=True, blocksize=10) -> record *

Summary
Get the range of values in the measurement set

Input Parameters:
items            Item names 
useflags         Use the data flags true 
blocksize        Set the blocksize in MB 10 

--------------------------------------------------------------------------------

Definition at line 396 of file ms.py.

def __casac__.ms.ms.regridspw (   self,
  args,
  kwargs 
)
regridspw(self, outframe=string("LSRK"), mode=string("chan"), restfreq=-3E30, interpolation=string("LINEAR"), 
    start=-3E30, center=-3E30, bandwidth=-1., chanwidth=-1., hanning=True) -> bool

Summary
transform spectral data to different reference frame and/or regrid the frequency channels
   

Input Parameters:
outframe         Name of the reference frame to transform to (LSRK, LSRD, BARY, GALACTO, LGROUP, CMB, GEO, or TOPO). If no reference frame is given, the present reference frame given by the data is used, i.e. the reference frame is not changed. The observatory position is taken as the average of all antenna positions. LSRK 
mode             The quantity (radio velocity (m/s), optical velocity (m/s), frequency (Hz), wavelength (m), or original channels) in which the user would like to give the regridding parameters below ('center', 'chanwidth', 'bandwidth'): vrad, vopt, freq, wave, or chan. chan 
restfreq         Required in case the value of mode is 'vrad' or 'vopt': Rest frequency (Hz) for the conversion of the regrid parameters 'center', 'chanwidth', and 'bandwidth' to frequencies. -3E30 
interpolation    Name of the interpolation method (NEAREST, LINEAR, SPLINE, CUBIC, FFTSHIFT) used in the regridding. Flagging information is combined using 'inclusive or'. LINEAR 
start            Desired lower edge of the spectral window after regridding in the units given by 'mode' and in the reference frame given by 'outframe'. If no value is given, it is determined from 'center' and 'bandwidth'. -3E30 
center           (Alternative to setting the parameter 'start'.) Desired center of the spectral window after regridding in the units given by 'mode' and in the reference frame given by 'outframe'. If no value is given, the center is determined from 'start' and 'bandwidth' or, if 'start' is not given either, it is kept as it is. -3E30 
bandwidth        Desired width of the entire spectral window after regridding in the units given by 'mode' and in the reference frame given by 'outframe'. If no value is given or the given width is larger than the bandwidth of the data, the width will be truncated to the maximum width possible symmetrically around the value given by 'center'. -1. 
chanwidth        Desired width of the channels in the units given by 'mode' and in the reference frame given by 'outframe'. This implies that channels will be equidistant in the unit given by 'mode'. If no value is given and 'mode' is vrad or freq, the function will keep the resolution as it is. If 'mode' is vopt or wave, the total number of channels will be kept as is. -1. 
hanning          If true, perform hanning smoothing before regridding. true 

--------------------------------------------------------------------------------

Definition at line 570 of file ms.py.

def __casac__.ms.ms.reset (   self)
reset(self) -> bool

Summary
Re-attach the tool to the original MS.
--------------------------------------------------------------------------------

Definition at line 233 of file ms.py.

def __casac__.ms.ms.select (   self,
  args,
  kwargs 
)
select(self, items=initialize_record("")) -> bool

Summary
Select a subset of the measurement set.

Input Parameters:
items            record with fields contain ranges and enumerations 

--------------------------------------------------------------------------------

Definition at line 507 of file ms.py.

def __casac__.ms.ms.selectchannel (   self,
  nchan = 1,
  start = 0,
  width = 1,
  inc = 1 
)
selectchannel(self, nchan=1, start=0, width=1, inc=1) -> bool

Summary
Select and average frequency channels

Input Parameters:
nchan            Number of output channels, positive integer 1 
start            First input channel to use, positive integer 0 
width            Number of input channels to average together, positive integer 1 
inc              Increment to next (group of) input channel(s), positive integer 1 

--------------------------------------------------------------------------------

Definition at line 537 of file ms.py.

def __casac__.ms.ms.selectinit (   self,
  datadescid = 0,
  reset = False 
)
selectinit(self, datadescid=0, reset=False) -> bool

Summary
Initialize the selection of an ms

Input Parameters:
datadescid       Data description id 0 
reset            Reset to unselected state false 

--------------------------------------------------------------------------------

Definition at line 459 of file ms.py.

def __casac__.ms.ms.selectpolarization (   self,
  args,
  kwargs 
)
selectpolarization(self, wantedpol=std::vector< string >(1, "")) -> bool

Summary
Selection and convertion of polarizations

Input Parameters:
wantedpol        The polarizations wanted 

--------------------------------------------------------------------------------

Definition at line 555 of file ms.py.

def __casac__.ms.ms.selecttaql (   self,
  args,
  kwargs 
)
selecttaql(self, msselect=string("")) -> bool

Summary
Select a subset of the measurement set.

Input Parameters:
msselect         TaQL selection string 

--------------------------------------------------------------------------------

Definition at line 522 of file ms.py.

def __casac__.ms.ms.setbufferflags (   self,
  args,
  kwargs 
)
setbufferflags(self, flags=initialize_record("")) -> bool

Summary
Set the flags in the buffer

Input Parameters:
flags            record with flag and flag\_row 

--------------------------------------------------------------------------------

Definition at line 1009 of file ms.py.

def __casac__.ms.ms.split (   self,
  args,
  kwargs 
)
split(self, outputms=string(""), field=initialize_variant(""), spw=initialize_variant("*"), step=initialize_vector(1, (int)1), 
    baseline=initialize_variant(""), timebin=initialize_variant("-1s"), 
    time=string(""), scan=initialize_variant(""), uvrange=initialize_variant(""), 
    taql=string(""), whichcol=string("DATA"), tileshape=initialize_variant(""), 
    subarray=initialize_variant(""), combine=string(""), 
    correlation=string(""), intent=string(""), obs=string("")) -> bool

Summary
make a new ms from a subset of an existing ms, adjusting subtables and indices

Input Parameters:
outputms         The name of the resulting measurement set 
field            Fields to include, by names or 0-based ids. ('' => all) 
spw              Spectral windows (and :channels) to select * 
step             number of input per output channels - Int vector of length 1 or same as spw 1 
baseline         Antenna names or indices to select ('' => all) 
timebin          Duration for averaging. Defaults to no averaging. -1s 
time             Only use data in the given time range, using the msselection syntax. 
scan             Only use the scan numbers requested using the msselection syntax. 
uvrange          Limit data by uv distance using the msselection syntax. 
taql             For the TAQL experts, flexible data selection using the TAQL syntax 
whichcol         'DATA', 'MODEL_DATA', 'CORRECTED_DATA', 'FLOAT_DATA', 'LAG_DATA', and/or 'all' DATA 
tileshape        Tile shape of the disk data columns, most users should not need to touch this parameter [0] => normal tiling, [1] => fast mosaic style tile [4,15,351] => a tile shape of 4 pol 15 chan and 351 rows 
subarray         Limit data to specific (sub)array numbers. 
combine          Ignore changes in these columns (scan, and/or state) when time averaging. 
correlation      Limit data to specific correlations (LL, XX, LR, XY, etc.). 
intent           Only use the requested scan intents. 
obs              Only use the requested observation IDs. 

--------------------------------------------------------------------------------

Definition at line 829 of file ms.py.

def __casac__.ms.ms.statistics (   self,
  args,
  kwargs 
)
statistics(self, column=string(""), complex_value=string(""), useflags=True, spw=string(""), field=string(""), 
    baseline=string(""), uvrange=string(""), time=string(""), correlation=string(""), 
    scan=string(""), array=string(""), obs=string("")) -> record *

Summary
Get statistics on the selected measurement set

Input Parameters:
column           Column name 
complex_value    Which derived value to use for complex columns (amp, amplitude, phase, imag, real, imaginary) 
useflags         Use the data flags true 
spw              Spectral Window Indices or names : example : '1,2' 
field            Field indices or source names : example : '2,3C48' 
baseline         Baseline number(s): example: '2&3;4&5' 
uvrange          UV-distance range, with a unit : example : '2.0-3000.0 m' 
time             Time range, as MJDs or date strings : example : 'xx.x.x.x.x~yy.y.y.y.y' 
correlation      Correlations/polarizations : example : 'RR,LL,RL,LR,XX,YY,XY,YX' 
scan             Scan number : example : '1,2,3' 
array            Array Indices or names : example : 'VLAA' 
obs              Observation ID(s): examples : '' or '1~3' 

--------------------------------------------------------------------------------

Definition at line 368 of file ms.py.

def __casac__.ms.ms.statwt (   self,
  args,
  kwargs 
)
statwt(self, dorms=False, byantenna=True, sepacs=True, fitspw=initialize_variant("*"), fitcorr=initialize_variant(""), 
    combine=string(""), timebin=initialize_variant("0s"), 
    minsamp=3, field=initialize_variant(""), spw=initialize_variant("*"), antenna=initialize_variant(""), 
    timerange=string(""), scan=initialize_variant(""), 
    intent=string(""), array=initialize_variant(""), correlation=string(""), 
    obs=string(""), datacolumn=string("corrected_data")) -> bool

Summary
Set WEIGHT and SIGMA from the scatter of the visibilities

Input Parameters:
dorms            How the scatter should be estimated (True -> rms, False -> stddev) false 
byantenna        How the scatters are solved for (by antenna or by baseline) true 
sepacs           If solving by antenna, treat autocorrs separately true 
fitspw           Line-free spectral windows (and :channels) to get the scatter from. ('' => all) * 
fitcorr          Correlations (V, LL, XX, LR, XY, etc.) to get the scatter from. ('' => all) 
combine          Ignore changes in these columns (spw, scan, and/or state) when getting the scatter. 
timebin          Duration of the moving window over which to estimate the scatter. Defaults to 0s, with an effective minimum of 1 integration. 0s 
minsamp          The minimum number of visibilities for a scatter estimate 3 
field            Fields to reweight, by names or 0-based ids. ('' => all) 
spw              Spectral windows to reweight. ('' => all) * 
antenna          Select data based on antenna/baseline 
timerange        Select data by time range 
scan             Scan numbers to reweight. ('' => all) 
intent           Scan intents to reweight. ('' => all) 
array            Select (sub)array(s) by array ID number 
correlation      Correlations (LL, XX, LR, XY, etc.) to reweight. ('' => all) 
obs              Observation IDs to reweight. ('' => all) 
datacolumn       Which data column to calculate the scatter from. corrected_data 

--------------------------------------------------------------------------------

Definition at line 792 of file ms.py.

def __casac__.ms.ms.summary (   self,
  args,
  kwargs 
)
summary(self, verbose=False, listfile=string("")) -> record *

Summary
(PARTIALLY IMPLEMENTED!!!) Summarize the measurement set

Input Parameters:
verbose          Produce verbose logging output false 
listfile         Output file 

--------------------------------------------------------------------------------

Definition at line 299 of file ms.py.

def __casac__.ms.ms.testconcatenate (   self,
  args,
  kwargs 
)
testconcatenate(self, msfile=string(""), freqtol=initialize_variant("1Hz"), dirtol=initialize_variant("1mas"), 
    respectname=False) -> bool

Summary
Concatenate only the subtables of two measurement sets excluding the POINTING table (resulting MAIN and POINTING table not useful)

Input Parameters:
msfile           The name of the measurement set from which the subtables should be appended 
freqtol          Frequency difference within which 2 spectral windows are considered similar; e.g '10Hz' 1Hz 
dirtol           Direction difference within which 2 fields are considered the same; e.g '1mas' 1mas 
respectname      If true, fields with a different name are not merged even if their direction agrees false 

--------------------------------------------------------------------------------

Definition at line 708 of file ms.py.

def __casac__.ms.ms.timesort (   self,
  args,
  kwargs 
)
timesort(self, newmsname=string("")) -> bool

Summary
Sort the main table of an MS by time

Input Parameters:
newmsname        Name of the output measurement set (default: overwrite original) 

--------------------------------------------------------------------------------

Definition at line 748 of file ms.py.

def __casac__.ms.ms.tofits (   self,
  args,
  kwargs 
)
tofits(self, fitsfile=string(""), column=string("corrected"), field=initialize_variant(""), spw=initialize_variant(""), 
    width=1, baseline=initialize_variant(""), time=string(""), 
    scan=initialize_variant(""), uvrange=initialize_variant(""), taql=string(""), 
    writesyscal=False, multisource=False, combinespw=False, writestation=False, 
    padwithflags=False) -> bool

Summary
Convert a measurement set to a uvfits file

Input Parameters:
fitsfile         Name of the new uvfits file 
column           Data column to write, see above for options corrected 
field            Field ids (0-based) or fieldnames to split out 
spw              Spectral windows to split 
width            number of input channels to average 1 
baseline         Antenna names or Antenna indices to select 
time             Limit data selected to be within a given time range. Syntax is the defined in the msselection link 
scan             Limit data selected on scan numbers. Syntax is the defined in the msselection link 
uvrange          Limit data selected on uv distance. Syntax is the defined in the msselection link 
taql             For the TAQL experts, flexible data selection using the TAQL syntax 
writesyscal      Write GC and TY tables false 
multisource      Write in multisource format false 
combinespw       Export spectral windows as IFs false 
writestation     Write station name instead of antenna name false 
padwithflags     If combinespw==True, pad data with flags to fit IFs false 

--------------------------------------------------------------------------------

Definition at line 266 of file ms.py.

def __casac__.ms.ms.uvsub (   self,
  reverse = False 
)
uvsub(self, reverse=False) -> bool

Summary
Subtract model from the corrected visibility data.

Input Parameters:
reverse          When False subtracts model from visibility data; when True adds model to visibility data false 

--------------------------------------------------------------------------------

Definition at line 1119 of file ms.py.

def __casac__.ms.ms.virtconcatenate (   self,
  args,
  kwargs 
)
virtconcatenate(self, msfile=string(""), auxfilename=string(""), freqtol=initialize_variant("1Hz"), dirtol=initialize_variant("1mas"), 
    weightscale=1., respectname=True) -> bool

Summary
Concatenate two measurement sets virtually

Input Parameters:
msfile           The name of the measurement set to append 
auxfilename      The name of a auxiliary file which is needed when more than two MSs are to be concatenated. 
freqtol          Frequency difference within which 2 spectral windows are considered similar; e.g '10Hz' 1Hz 
dirtol           Direction difference within which 2 fields are considered the same; e.g '1mas' 1mas 
weightscale      Scale the weights of the MS to be appended by this factor 1. 
respectname      If true, fields with a different name are not merged even if their direction agrees true 

--------------------------------------------------------------------------------

Definition at line 727 of file ms.py.

writebufferflags(self) -> bool

Summary
Write the flags in the internal buffer back to the table.
--------------------------------------------------------------------------------

Definition at line 1024 of file ms.py.

def __casac__.ms.ms.writehistory (   self,
  args,
  kwargs 
)
writehistory(self, message=string(""), parms=string(""), origin=string("MSHistoryHandler::addMessage()"), 
    msname=string(""), app=string("ms")) -> bool

Summary
Add a row of arbitrary information to the measurement set history table

Input Parameters:
message          Message to be recorded in message field 
parms            String to be written to input parameter field 
origin           String to be written to origin field MSHistoryHandler::addMessage() 
msname           name of selected measurement set 
app              String to be written to application field ms 

--------------------------------------------------------------------------------

Definition at line 348 of file ms.py.


Member Data Documentation

__casac__.ms.ms.__del__ [static, private]

Definition at line 83 of file ms.py.

tuple __casac__.ms.ms.__getattr__ [static, private]

Definition at line 75 of file ms.py.

__casac__.ms.ms.__repr__ [static, private]

Definition at line 76 of file ms.py.

tuple __casac__.ms.ms.__setattr__ [static, private]

Definition at line 73 of file ms.py.

Definition at line 82 of file ms.py.

dictionary __casac__.ms.ms.__swig_getmethods__ [static, private]

Definition at line 74 of file ms.py.

dictionary __casac__.ms.ms.__swig_setmethods__ [static, private]

Definition at line 72 of file ms.py.

Definition at line 81 of file ms.py.


The documentation for this class was generated from the following file: