Getting Started Documentation Glish Learn More Programming Contact Us
Version 1.9 Build 1488
News FAQ
Search Home


next up previous contents index
Next: bimacalibrater - Tool Up: BIMA Previous: bimams.totalintegrationtime - Function


bimacalibrater - Module

Postscript file available

Module for calibrating BIMA data
include "bimacalibrater.g"



Description

The bimacalibrater module provides functions for calibrating BIMA data.

The facilities of the bimacalibrater module are made available in Glish by issuing the following command:

- include 'bimacalibrater.g'
T

where a hyphen precedes user input. The Glish response is indicated without the prompt.

A bimacalibrater tool is created and attached to a specified set of measurement sets as indicated in the following example:

- bc := bimacalibrater(['sgrb2.ms','sgra.ms'],'1733-130.ms',
+ targetnames=['sgrb','sgra'],phcalnames='1733')

Many functions of bimacalibrater are wrappers around corresponding functions in calibrater. One important exception is transfer() which transfers the solutions from one calibration table (usually the one written by solve()) to another table (generally the one that will be applied to the target source with correct()). This is generally a necessary step because, for BIMA data, the calibration solutions are determined for a small set of spectral windows (e.g., the two sideband averages [the wideband data in miriad parlence]), but these solutions must be applied to all the windows in the target datasets. The only way to do this in AIPS++ is to create a new calibration table which reflects the number of spectral windows in the target sources.

Essentially, a bimacalibrater tool creates (on demand) and stores calibrater tools attached to the Measurement Sets specified in the bimacalibrater tool constructor. This tool's various functions manipulate these calibrater tools. In general, the functions take a parameter called sources which tells the function which calibrater tools it should manipulate. The sources parameter takes a vector of strings. The strings are source nicknames (see below) and/or source roles. Recognized roles are 'all' (all sources), 'targets' (target sources), 'phcals' (phase calibrators), 'pbcals' (passband calibrators), and 'fcals' (flux calibrators). The source roles are specified by the user when the tool is constructed (see below).

Here is an example of what a typical calibration session using bimacalibrater might look like:

bc := bimacalibrater('sgrb2.ms','1733-130.ms',targetnames='narrow',
   phcalnames='wide');
bc.setjy(fluxdensity=[5,0,0,0]);
bc.setsolve(type='G',refant=4,table='gcal',t=600);
bc.solve();
bc.fit();
bc.transfer('gcal.xfer','gcal');
bc.setapply();
bc.correct();

Here, a bimacalibrater tool is constructed by specifying a list of target sources ('sgrb2'), nicknames for these sources ('narrow'), a list of phase calibrators ('1733-130.ms'), and a list of nicknames for these calibrators ('wide'). The nicknames are optional and are meant to provide an easy way of referring to datasets (sometimes the names of measurement sets can be long, especially when fully qualified paths must be specified). The nicknames need not be provided, in which case they are set to the names of the corresponding measurement sets.

The flux density scale of the calibrater is set with setjy (which is actually a wrapper of the imager function of the same name). This function will optinally look up the flux density of the calibrator from the BIMA calibrator flux density table and write the flux desnity nearest in time to the observations to the measurement set. Next, the solver is set up using setsolve() and solutions are generated using solve(). Both are wrappers around calibrater functions of the same names.

The fit() function launches the gainpolyfitter GUI which allows one to interpolate the solutions by fitting polynomials to them.

The transfer() function is the reason bimacalibrater exists. The usual procedure of calibrating BIMA data is to generate solutions for the sideband average data of the calibrator. Solutions from these two windows are then applied to all the windows of target source. However, in AIPS++ the number of windows in the calibration table must be the same as the number in the dataset to which it is being applied. Therefore, the solutions in the gcal table, which contains only two windows, must be transferred to a new table gcal.xfer which has the same number of windows as the target source dataset (e.g. 10 [2 sideband average windows + 8 channel data windows]). Once this is done, further information on how to apply the solutions can be provided with setapply() and finally the solutions can be applied with correct().

Tools
bimacalfluxtable Tool to retrieve information from the BIMA calibrator tables
bimacalibrater Calibration of BIMA data

Functions
bimacalibratertest Test bimacalibrater




next up previous contents index
Next: bimacalibrater - Tool Up: BIMA Previous: bimams.totalintegrationtime - Function   Contents   Index
Please send questions or comments about AIPS++ to aips2-request@nrao.edu.
Copyright © 1995-2000 Associated Universities Inc., Washington, D.C.

Return to AIPS++ Home Page
2006-08-01