[ Basic Info | References | User Guide ]
Basic Information on smagpplt
Task: smagpplt
Purpose: Plot,smooth and fit to gain and bandpass.
Categories: calibration
SmaGpPlt is a MIRIAD task which plots and lists antenna gain and
bandbass. The plot for gains is against time. The
plot for bandpass is against the frequency. SmaGpPlt provides
options to moving smooth or orthogal polynomial fit to the
gain/bandpass solutions and to over write the old gain/bandpass
tables with the smoothed or polynomial fit results. In addition,
SmaGpPlt allows to compare bandpass solutions in two vis files.
SmaGpPlt can also merge two gain tables computed (using either
SmaMfCal or MfCal from two calibrators that were observed
interleavely.
Key: vis
The name of the input data-set. This will normally be a visibility
data-set. No default. If two files are given, options must be
either 'bandpass' or 'gains,merge'.
Key: device
The PGPLOT plotting device to use. The default is no plot.
Key: log
The log to give a listing of the gains and polarization terms. The
default is no log.
Key: xaxis
This specifies the variable of the x-axis in plot when options
is given as 'bandpass':
chan Plot/list channels.
freq Plot/list frequencies.
If nothing is given, 'freq' is assumed.
For options=gains, only time (UT) of x-axis is supported.
Key: yaxis
This specifies what is to be plotted/listed. Several values can be
given, separated by commas. Minimum match is used:
amp Plot/list amplitudes. This is the default if the gains
are being plotted/listed, and nothing else is requested.
phase Plot/list phases.
real Plot/list the real parts. This is the default if the
polarization terms are being plotted/listed, and nothing
else is requested.
imag Plot/list the imaginary parts.
If nothing is given, 'amp' is assumed.
Key: options
Some extra processing options can be given. Several values can be
given, separated by commas. Minimum match us used.
gains Plot/list the gains vs time. This is the default if
nothing else is requested.
bandpass Plot/list the bandpass shape vs frequency.
dots Plot things as dots (rather than chunky circles).
dtime Give time in days and fractions of a day. This is more
useful for listing files which are to be passed into
some other analysis or plotting tool.
wrap Don't unwrap phase plots.
msmooth Do moving average of the bandpass/gain curve using
the smooth parameters and replace old one.
weight This gives weight in the orthogonal polynomial
least-square fit to the antenna gain
curves.
<1 => weight = 1, uniform weight.
1 or greater => weight = the sqaure of amplitude
of 1/g, where g is a complex antenna gain
derived within a solutional interval.
The default is 1.
opolyfit Do least-square fit to the bandpass/gain curves
with an orthogonal polynomial of degree n and replace
old one. Only one of the options is allowed in
the replacement of the gain/bandpass. Please choose
either msmooth or opolyfit.
ratio do ratio (bp1/bp2) in comparison of two bandpasse
solutions if Keyword vis is given two input vis files.
The default is to compare the difference (bp2-bp1).
merge merge two gain tables associated with the two
visibility files respectively. Two input vis
files must be given. The merged gain table
will be placed in the second input vis file
by overwritting on the old gain table.
xpass transfers the bandpass solution from the image
side band (1st input file) to the target side
band (the 2nd input file) by reversing
the channel sequence of the solutions while
the frequency tables are kept unchanged.
vis must be given by two files containing
'bandpass' and 'freqs' produced from the
image bands (chunks) of the opposite
sidebands.
nofit does not display polynomial fitting or
moving smooth curves on the gains/bandpass
solution plots.
Key: filelabel
This gives an option to label the file name in the plot:
filelabel = -1, not to label the file name, the default;
filelabel = 0, label the file name to each of panel plots;
filelabel = 1, label the file name to the 1st panel in
the case of multiple panels.
Key: smooth
This gives three parameters of moving smooth calculation of the
bandpass/gain curves
smooth(1) = K parameter k giving the length 2k+1 of the averaging
interval; default is 3.
If smooth(1) =0, then polynomial fit will be
taken.
smooth(2) = L order of the averaging polynomial l; default is 3.
smooth(3) = P probability P for computing the confidence limits;
default is 0.9.
Key: polyfit
polyfit(1) gives a degree of orthogonal polynomial in least-sqaure
fit to the bandpass/gain curves. Default is 0 (moving smooth).
If polyfit(1)=0, then the moving average is taken.
If polyfit(2)>0, then the Chi-square parameters as function
of a polynomial order 1 (linear) , 2 (parabolic),
3 (cubic), 4, 5 are reported for each antenna
and each spectral window. The minimum Chi-square corresponds to
the best fit in orthogonal polynomial regression.
Key: nxy
Number of plots in the x and y directions. The default is 2,2.
Key: select
A subset of the normal uv-selection parameters. They are not
entirely consisently used. Antenna and time selection is supported
for gains. Time selection is supported for delay and spectral
correction. Antenna and frequency selection is supported for
bandpasses. The default is to select everything.
Key: yrange
The min and max range along the y axis of the plots. By default
gpplt autoscales. If the ``yrange'' parameter is given, then this
range is used on ALL plots. So it may not make much sense to
plot different sorts of quantities (e.g. amplitude and phases)
when explicitly giving the plot range.
Key: dotsize
Allows users to choose a symbol (dot) size in a range between
1-201. The actual plotted dot size depends on the device
resolution. Other internal symbol selecting function
would be failed when this parameter is in use.
Default is to disable this function.