NRAO Home > CASA > CASA Toolkit Reference Manual
msmetadata.statesforscans - Function

1.3.2 Get a dictionary which maps scan numbers to state IDs for the specified array and observation IDs.


Description

Get a dictionary which maps scan numbers to state IDs for the specified array and observation IDs. The returned dictionary will have scan numbers, as strings, as keys.

Arguments





Inputs

obsid

Observation ID, must be nonnegative.

allowed:

int

Default:

0

arrayid

Array ID, must be nonnegative.

allowed:

int

Default:

0

Returns
record

Example

 
    msmd.open("my.ms")  
    # get the map of scan numbers to state IDs for arrayID=1, obsID=2  
    scans_to_states = msmd.statesforscans(obsID=2, arrayID=1)  
    states_for_scan_5 = scans_to_states[str(5)]  
    msmd.done()  

__________________________________________________________________


More information about CASA may be found at the CASA web page

Copyright 2016 Associated Universities Inc., Washington, D.C.

This code is available under the terms of the GNU General Public Lincense


Home | Contact Us | Directories | Site Map | Help | Privacy Policy | Search