.ec _
.ll 76
.ad b
.in 4

.ti -4 
1 Language
.ti +4
.nf
                     CLIC\ Command Language Summary

             Continuum and Line Interferometric Calibration

ATMOSPHERE      : Perform atmospheric calibration. 
BLANK           : Blank some spectral channels
COMPRESS        : Compress data.
COPY            : Copy data.
CURSOR          : Call the interactive graphic cursor.
DIRECTORY       : List files matching a pattern into SIC variables.
DROP            : Take a scan out of the current index.
DUMP            : List some informations on the R spectrum.
FILE            : Define the input/output files.
FIND            : Search the input file for observations.
FITS            : Write out spectra in FITS format (e.g. for CLASS).
FLAG            : Flag data.
FREE            : Free internal virtual-memory buffers.
GET             : Read a scan in the input file.
HEADER          : Display some header information.
IGNORE          : Ignore scans from the input file.
LIST            : List header information about an ensemble of scans.
MARK            : Force data to be treated as if flagged.
MASK            : Cause some flags to be ignored.
MINMAX          : compute extremal amplitudes in data
MODIFY          : Edit and change the scan header (and data).
MONITOR         : Process data for total power phase correction parameters.
NEW__DATA        : Wait until new data present in input file.
PLOT            : Plot data according to display options.
POPUP           : Pop-up a plot box and redraw it in a temporary window.
PRINT           : Produces an output text file (PRINT BASELINE).
RESIDUALS       : Plot residuals from last SOLVE operation.
SET             : Enter a value for a parameter.
SG__TABLE        : Create a UV data Table for mapping purposes.
SHOW            : Show current value for a parameter.
SOLVE           : Solve for calibration functions.
STORE           : Store calibration functions.
TABLE           : Create a UV data Table for mapping purposes.
TAG             : Change the quality of scans in the output file.
VARIABLES       : Enable/disable CLIC variables
WVR             : Process data for WVR phase correction parameters.
.fi

.ti -4
1 ATMOSPHERE
.ti +4
CLIC\ATMOSPHERE [DETECTOR|CORRELATOR] [/COMPRESS] [/RESET] 
.ti +4
[/NOWRITE] [/NOMONITOR]

Recompute the atmospheric (transparency) calibration from the data and
the informations provided by the SET ATMOSPHERE command. All scans in
the current index are processed:

.in +4
.ti -2 

- Atmospheric calibration scans (CALI): compute calibration
temperature Tcal, using either the total power DETECTORs or the
continuum CORRELATOR to measure the atmospheric emission. Default is
DETECTOR. The data on the atmospheric monitor (the 1.3 mm) receiver
will also be used to compute the phase correction factors (see also
the MONITOR command).

.ti -2
- Apply the new model to the subsequent observations and write
(update) the recalibrated data if option /NOWRITE is not present. This
is done until a new calibration is found.
.in -4

[/COMPRESS] Obsolete option.

[/RESET] ALL|AUTO|CAL Reset integrations time associated to ALL phases,
SKY phase, or HOT/COLD cal phases.

[/NOWRITE] Do not update data on disk.

[/NOMONITOR] Do not compute and update monitoring section.

.ti -4
1 BLANK
.ti +4
CLIC\BLANK c1 c2 /SPW i [/RESET] [/EXTRAPOLATE] [/NOEXTRAPOLATE]
          [/ANTENNA a1 [...]]

Blank channels c1 to c2 in spectral window i (mandatory argument).
With option /reset, it will reset all ranges blanked in spectral window i.
Option /ANTENNA applies the blanking to selected antennas only; /ANTENNA ALL
selects all antennas and is the default when /ANTENNA is omitted. Current list
can be obtained with command SHOW BLANK.

Options [/EXTRAPOLATE] and [/NOEXTRAPOLATE] control CLIC behaviour regarding
blanked data. They will be either interpolated or blanked accordingly.
.ti -4
1 COMPRESS
.ti +4
CLIC\COMPRESS timemax uvmax [/TRIANGLE]

Compress data in the current index by averaging successive records
in  individual  scans.  'timemax'  is  the  maximum  averaging  time in
seconds.  Data with baseline orientation differing by  more 'uvmax'  in
meters  in  the  UV  plane  are  not  averaged,  as well as data flagged
differently.

Defaults for timemax and  uvmax  are  60  seconds  and  7.5  meters
respectively.   An  output  file  must  have  been opened to receive the
compressed data.

Use command COPY rather than COMPRESS to copy the whole current
index to a new file.

For data taken after September 1992 (new correlator), the command
will only  compress  the  temporal  data (data header  and  continuum
subbands), since the spectral data is already compressed to 1 record
per scan.

[/TRIANGLE] add triangles to data. Not tested.

.ti -4
1 COPY
.ti +4
CLIC\COPY HEADERS|[NO]DATA [[NO]BASE] [[NO]ANTENNA] [NORF] [/EXTRACT]

Copy the content of the current index to the ouput file.  The first
argument is mandatory and controls whether the data section is
actually written in the output file or not.

COPY DATA selects the old mode, in which the data as well as the
headers are copied in the output file.

COPY HEADERS selects the RECOMMENDED mode in which only the 
headers are copied in the output file. In this new so-called "header
file", the data sections are not written but replaced by pointers to
the original file. This way, the data file, originally written at
Plateau de Bure, is later only used in a read-only mode. All further
calibrations are stored in the (much smaller) header file. It is
HIGHLY RECOMMENDED to use the extension ".hpb" for the new file
containing the headers.

.nf
Example:
!
! Original file is "14-apr-1996-f081.ipb".
! Create a header file:
! 
file in 14-apr-1996-f081.ipb
find
file out f081-b2.hpb new
copy headers
!
! Now open the f081-b2.hpb for input/output
!
file both f081-b2
find
solve phase /plot
store phase 
! 
! ... and so on as usual
!  
.fi

When the header file is opened for input, CLIC will look for the
data sections in the original (read-only) data file.  The original
data file may be kept locally or reside in any directory, which is
pointed to by one of the logical names "IPB__DATA:", "IPB__DATA1:" to
"IPB__DATA9:". The original file name MUST BE UNCHANGED, apart from
the extension.   

Most commands are available in this mode, even commands that affect
data amplitudes phases such as ATMOSPHERE, MODIFY BASELINE or MODIFY
DELAY. The phase factors are kept in the headers and applied only when
the data will be later read again.

There need not be a one to one correspondence between the original
".ipb" file contents and the ".hpb" header file. The header file may
refer to only part of the scans in the .ipb file (e.g. omit the IFPB
or POINT scans), and it may refer to several .ipb files (e.g. data
from two consecutive days).

Arguments [NO]BASE and [NO]ANTENNA control whether respectively the
baseline and antenna-based calibration sections are written in the
header file. Antenna-based calibration is now the default and omitting
the baseline-based sections saves a lot of space. Do not forget to use
COPY HEADERS BASE if you foresee you will need baseline-based
calibration. 

Argument [NORF] can be used to tell that one wishes to skip the passband
calibration sections regardless of the ANTENNA or BASE arguments. It is 
used in view of storing RF bandpass solution as an extra scan
with the STORE RF /SCAN option.

Option [/EXTRACT USB|LSB] will extract only the selected sideband.

.ti -4
1 CURSOR
.ti +4
CLIC\CURSOR [mode]

Call the interactive cursor, if available on your graphic terminal.
This enables you to measure point coordinates and perform some data
editing on the result of a PLOT command.

After pressing any key, one of the data points is selected according
to the argument `mode'. In mode D the closest data point from the
cursor is selected; in mode X (the default) the data point with
closest X coordinate is selected; in mode Y the data point with
closest Y coordinate is selected.

The following actions are possible:

.in +4
.ti -2
- Press any key to get the coordinates of the selected point.

.ti -2
- Press 'H' to display some header information of the selected
scan (as with LIST command).

.ti -2
- Press 'K' to delete the selected point from the current plot buffers
(type PLOT SAME to replot the buffers). This may be very useful to
remove corrupted points from the buffers e.g. before fitting
calibration curves.

.ti -2
- Press 'N' to initiate a new range for  Ignore,  Tag,  and  Flag (see
below).  This works only with time-like plots,  and  is to  be  used
preferrably  with coordinates that are monotonous functions of time
(scan number, observation number, time, ...)

.ti -2
- Press 'I' to ignore all scans in the current  range (initiated by 'N'). 
This is equivalent to typing the IGNORE command for the same
scans.  

.ti -2
- Press 'T' to tag all scans in the current range  (initiated  by 'N').
This is  equivalent  to typing the TAG command for the same scans.  You
will be prompted for a quality code in the range  0 to  9 (see TAG
command). The quality codes are stored in the output file, which must
be equal to the input file.

.ti -2
- Press 'F' to flag all records in the current range (initiated by 'N').
You will be prompted for a list of flags (see FLAG command). These flags 
will affect the baseline or antenna corresponding to the box you are
pointing at. They will be stored in the output file,  which must
be equal to the input file. 

.ti -2
- Press 'E' to exit the cursor mode.
.in -4

.ti -4
1 DROP
.ti +4
CLIC\DROP observation [version]

Remove an observation from the current index. The  version  number must
be specified if it is not the last in the input file, even if it is the
last in the current index. The observation will be ignored until the 
next FIND command. See also the IGNORE command.

.ti -4
1 DIRECTORY
.ti +4
CLIC\DIRECTORY [filespec]

Build a directory listing and store it into SIC variables. If "filespec" is
omitted, the default pattern is "*.hpb".

The following SIC variables are defined (overwriting any previous values):

.nf
  DIR_NFILE            Number of files found
  DIR_FILE(1:DIR_NFILE)  File names
.fi

If "filespec" contains a SIC logical name followed by ':', the logical is
expanded before listing the files.

.ti -4
1 DUMP
.ti +4
CLIC\DUMP arguments [/PLOT]

A debugging command that lists a certain number of informations on the
last read observation.    

.in +4
.ti -2
- DUMP HEADER argument: lists a certain number of informations about
the observation header.  Argument may be ALL, HEADER, GENERAL,
POSITION, INTERFEROMETER, FREQUENCY, ATMOSPHERE, MONITOR, CONTINNUM,
LINE (with optional argument 'iband', dump only subband 'iband'), 
SCANNING, IC (Instrumental calibration), AIC (Antenna-based
Instrumental calibration), PC (RF Passband calibration), APC
(Antenna-based RF Passband calibration), DD (Data Descriptor), WVR
(Water Vapor radiometer), PHASES.

.ti -2
- DUMP DATA: lists the data associated parameters.

.ti -2
- DUMP FILE: lists information about the input and output files.

.ti -2
- DUMP INDEX: lists information about the current index.

.ti -2
- DUMP VIRTUAL: gives  the  virtual  memory  and  paging  file
quotas.

.ti -2
- DUMP SIZE: gives the values of a number of key variables that 
define the size of the problem.

.ti -2
- DUMP BUFFER: dumps levels for atmospheric calibration (for debugging).

.ti -2
- DUMP RF: dumps antennas used for RF calibration (for debugging),

.ti -2
- DUMP SBA: dumps the sideband average (for debugging).

.ti -2
- DUMP CONTINUUM: dumps the continuum data.

.ti -2
- DUMP LINE c1 c2:  dumps the spectral data from channel  c1  to c2.
DUMP LINE c1 c2 /PLOT  will  plot  the  spectral data amplitude as a
function of channel number.
.in -4

DUMP DATA, DUMP CONTINUUM and DUMP LINE will return the phase-corrected
or uncorrected data, depending on the last SET PHASE ATM or SET PHASE
NOATM command issued.

.ti -4
1 FILE
.ti +4
CLIC\FILE [type] [name] [NEW] [/WINDOW] 

Selects the input and output files. 

.nf
FILE IN Name            defines the input file.
FILE OUT Name [NEW]     defines the output file, and 
                        initializes it if NEW is precised.
FILE BOTH Name          selects the same file for input and output.
.fi

The default filename extension is ".hpb". With FILE IN, the extension
".ipb" is also checked. This behaviour can be changed using the
command SET EXTENSION. The character variable SHORT__FILE is available
after a FILE IN: it contains the file name without directory or
extension. With option /WINDOW (if the windowing system is active), a
panel window is created and the file name may be selected via a file
browser ('Name' is then used as a filter). Pressing GO will then open
the file.

.ti +4
CLIC\FILE RAW [project] [date] [/WINDOW] [/DIRECTORY]

FILE RAW [Project] [Date] will select the first file residing in the
directories IPB__DATA:, IPB__DATA1:, ..., IPB__DATA9:, which matches
the optionally given project name and date, following the standard
name convention used at Plateau de Bure (jj-mmm-yyyy-proj.ipb, or
YYMMJJPROJCODE.IPB in the archive). The names of all the NFILE files matching
the project name and date are put in character array DATAFILE[NFILE]
(the integer variable NFILE is also defined).

FILE RAW [Project] [Date] /WINDOW (if the windowing system is active)
will create a panel window with a menu to select one of the available
files, and two action buttons, one for opening the file, the other for
creating a header file for calibration. 

FILE RAW /DIRECTORY (if the windowing system is active) creates a
panel window with a menu to edit the list of raw data file directories
(logical names IPB__DATA:, IPB__DATA1:, ...)

.ti -4
1 FIND
.ti +4
CLIC\FIND [APPEND] [NEW__DATA] [UPDATE] [/LINE lname] [/NUMBER n1 n2] 
.ti +4
[/SCAN s1 s2 [s3 s4 ...]] [/OFFSET o1 o2] [/PROCEDURE proc1 [...]] 
.ti +4
[/QUALITY q] [/SOURCE s1 s2 ... sn] [/TELESCOPE tel] [/TYPE type]
.ti +4
[/RECEIVER number] [/MODE CORR|AUTO] [/LOAD HOT|COLD|SKY]
.ti +4
[/SKIPAUTO] [/EXCLUDE proc1 [...]] [/CORRELATOR n] [/POLAR]

FIND performs a search in the input file to build a new index,
according to selection criteria defined by the SET command.  These
criteria can be listed with the SHOW CRITERIA command. They may be
temporarily modified by the following options :
        
.nf
/TYPE type           search by source type
/LINE lname          search by line name
/NUMBER n1 n2        search for the specified range of obs. numbers
/SCAN s1 s2 [s3 s4]  search for the specified range(s) of scan numbers
/OFFSET o1 o2        search for these offsets
/SOURCE s1 ... sn    search by source name
/PROCEDURE p1 .. pn  search by procedure name(s)
/QUALITY q           search for the data of quality better than q
/TELESCOPE tel       search for the specified telescope name             
/RECEIVER number     search by receiver number
/MODE mode           search by correlation mode (auto/cross)
/LOAD load           search by load type (hot/cold/sky)
/SKIPAUTO            skip the autocorrelations in cross scans
/EXCLUDE             exclude from the search by procedure name(s)
/CORRELATOR n        search by correlator number
/POLARISATION        search by polarisation subscan
.fi

FIND /SCAN s1 s2 [s3 s4 ..] will loop across the 9999/0001 border if
s1 (s3) is larger than s2 (s4). Using several source names in FIND
/SOURCE is now supported. Source name and Line name matching is not
case sensitive.

The current index is ordered by scan number or receiver number
depending on the last command SET SORT issued. However the scan
ordering is done modulo 9999 (i.e. the time order is respected if the
9999/0001 transition occurs in the current index).

FIND by default overwrites the current index.  Found observations may
be appended to the current index by specifying the argument APPEND;
an index compression occurs to avoid duplication of scans in the
index.

FIND does not return an error if the index is empty, but the variable
FOUND is set to 0. FOUND is always set to the number of observations
in the index. The command IGNORE can be used to declare a list of
observations to be ignored by the FIND command.

Argument NEW__DATA can be used to wait until new data is present in
the input file.  This possibility is intended for sites where data
acquisition is done in CLIC format (Plateau de Bure) to use CLIC as an
automated quick look facility.  The behaviour is similar to that of
command NEW__DATA, but all selection criteria are considered.

Argument UPDATE will perform a FIND using an updated input file, in case
new observations were added since the last FILE IN.

Options /SOURCE, /PROCEDURE, /EXCLUDE and /SCAN have a maximum number
of arguments (20 sources, 10 procedures kept or excluded and 100 scan
ranges). Input list will be truncated with a warning if needs be.

.ti -4
2 /POLAR
.ti +4
CLIC\FIND /POLAR argum
 
Find scan corresponding to a given state. 0 means direct, 1 means all
crossed. Valid values include 0 and 1 to 16 (corresponding to the 
polarisation subscans).



.ti -4
1 FITS
.ti +4
CLIC\FITS name [/PLOT] [/BASELINE b] [/ANTENNA a] [/OVERWRITE]

Create for each selected line subband a FITS file containing the
spectral data. The fits file names are e.g. name-l01.fits,
name-l02.fits, name-l03.fits (one fits file is created for each
subband), if one has specified SET SUBBAND L01 L02 L03.

For autocorrelation data, the data from all antennas are averaged.
For correlation data, the complex data from all baselines are averaged
and the real part of the resulting visibility is used.

Option /ANTENNA exports a single logical antenna for autocorrelation
data instead of averaging all antennas together.
Option /BASELINE exports a single logical baseline for correlation
data instead of averaging all baselines together. The baseline label
uses the same logical notation as in SET BASELINE.
Option /PLOT displays the selected spectrum before writing the FITS
file.

Only one selector can be specified. Use /ANTENNA only for
autocorrelation data and /BASELINE only for correlation data.
Option /OVERWRITE allows replacing an existing output FITS file.

This command allows to easily write out spectra from 
point-like sources to be further analyzed in CLASS. Reading the
data in CLASS and writing them in a CLASS-format file 
can be done with a procedure like:

.nf
    FILE OUT myfile NEW
    FITS READ name-l01.fits
    WRITE next__obs
    FITS READ name-l02.fits
    WRITE next__obs
    etc..
.fi

.ti -4
1 FLAG
.ti +4
CLIC\FLAG f1 f2 ... [/ANTENNA a1 [...]] [/BASELINE b1 [...]] 
.ti +4
[/RESET]

Flag the current record (obtained by GET /RECORD) with flags f1 f2 ...

Flags may be relative to antennas or baselines. One of the options
/ANTENNA or /BASELINE, with lists of antenna numbers or baseline names
as arguments, must therefore be given. /ANTENNA ALL will flag all
antennas, /BASELINE ALL will flag all baselines.  These are the
default.

Supported flag names are:

.nf
- C01 to C08 for bad individual continuum correlator subbands
- L01 to L08 for bad individual spectral correlator subbands
- DATA for bad data
- TSYS for too high system temperature (antenna based only)
- LOCK for out of lock local oscillator (antenna based only)
- POINTING for poor pointing (antenna based only)
- SHADOW for antenna being shadowed by another antenna (ant. based only)
- SATURATION for too high total power on a particular antenna
- TIME for time discontinuity
- DOPPLER for doppler discontinuity
- REDU for data reduction 
.fi

Use option /RESET to suppress flags that were accidentally set.

FLAG with no argument lists the flags of the current record.

This command may be used in a MODIFY DATA or MODIFY RECORD loop, to
flag data. If more than one record is to be flagged, command STORE
FLAG is HIGHLY RECOMMENDED.

.ti -4
1 FREE
.ti +4
CLIC\FREE

Release internal virtual-memory buffers used to cache file sections in memory.
This can be used to reduce memory usage or to force subsequent GET operations
to reload data from disk.

.ti -4
1 GET
.ti +4
CLIC\GET [n|FIRST|NEXT] [/RECORD r] [/HEADER] [/ATM]

GET loads the observation number n. If n is absent, the previous (last
read) observation is recovered. If instead of a number the keyword
"FIRST" is given, the first observation of the current index is
loaded. With "NEXT", the next observation in the current index is
loaded.

If option /RECORD is present, only record r is loaded. Otherwise, the
average record is loaded; it contain by default the uncorrected
data unless option /ATM is present, in which case the phase-corrected
record is loaded if it exists.

If option /HEADER is present, only the scan header is read.  No data
record is accessed. This command does not access the data file if only
the header file is available.

.ti -4
1 HEADER
.ti +4
CLIC\HEADER [/PLOT] [/LIST]

Displays some header information on the current observation.  

.nf
     General information line 
         Observation number 
         Scan number
         Project Id
         Source name
         Source type (Object or Phase calibrator)
         Procedure name
         Interferometer configuration
         Date of observation
         UT of observation
         Hour angle

     Position information line					
         RA or L : right ascension or longitude (or azimuth)
         DEC or B : declination or latitude (or elevation)
         Epoch if equatorial coordinates are used
         Offsets in current units
         Type of coordinate (Eq, Ga, Ho)
         Flux of the source 
 
     Quality information line
         Quality code
         Flag
         Receiver number
         Number of dump
         Azimuth
         Elevation
	
     Spectral line information line
         Line name
         Rest frequency
         Sideband 
         Doppler correction
         Source velocity  

     Correlator information, for each subband
         Logical name
         Width (MHz)
         Central IF (MHz)
         Physical unit
	 Quarter [for new receivers only]
	 Polarization [for new receivers only]
	 Narrow-band correlator input [for new receivers only]

     Interferometer status, for each antenna
         Antenna number
         Station
         Azimuth, Elevation, Focus corrections
         Receiver temperature (K)
         Image rejection (dB)
         Water (mm)
         System temperature (Tsys)
.fi

Argument /PLOT will produce an ASTRO like plot of the spectral setup.

Argument /LIST list the spectral windows and their rest frequencies.

.ti -4
1 IGNORE
.ti +4
CLIC\IGNORE list__of__observations

This command can be used to declare the specified list of Observations
(from the input file) to be ignored in all FIND operations.  They
effectively become invisible to CLIC (except in a LIST IN command),
until a FILE IN command is typed again.  The input file is not
physically modified however.  The list of observation can be given
using the same format as with a FOR command (e.g. n1 n2 n3 TO n4 BY n5
n6 TO n7).

.ti -4
1 LIST
.ti +4
CLIC\LIST [key] [/BRIEF] [/LONG] [/OUTPUT file] [/SHORT]
.ti +4
[/PROJECT] [/SOURCE] [/VARIABLE var__list [/FORMAT format__list]]
.ti +4    
[/OFFSET] [/FLAG [/MEMORY]] [/TELESCOPE] [/BANDPASS]

This command lists header information of an ensemble of observations.
LIST is used for a quick look to observation headers, in a more or
less detailed format. 'Key' specifies the file to be listed: IN or
OUT; if 'Key' is not present, the current index (as determined by the
last FIND command) is listed. The list will be ordered by scan numbers
or by receiver number, depending on the command SET SORT
SCAN|RECEIVER|NUM. For each observation, a medium-sized format is used by
default. This can be modified using the options:

.in +4
.ti -4
LIST /BRIEF 

Brief format (observation numbers and version numbers only).

.ti -4
LIST /LONG 

Long format (not allowed for the output file). Several 
lines can be listed for each scan, that can be selected using 
the SET FORMAT command.

.ti -4
LIST /SHORT 

Gives only one line for a set of scans with same parameters; IFPB and
CALI are not listed. The first and last scan of each group are logged
in array S__GROUP[2,N__GROUP], N__GROUP is the number of groups.  
.in -4

The output of the LIST command can be written in an output file
instead of the terminal using the "/OUTPUT File" option.  LIST can
also be used to to list a number of specific parameters:

.in +4
.ti -4
LIST /FLAG [/MEMORY]

List data flags for current index. With option /MEMORY, will list flags
in memory (see STORE FLAG /MEMORY).

.ti -4
LIST /PROJECT 

List the observing projects in the current index. The number 
of differents offset positions is in variable N__OFFPOS, the offsets are 
in array OFF__POS[2,N__OFFPOS].

.ti -4
LIST /SOURCE 

List the observed sources in the current index. The number of 
different source is in variable N__SOURCE, the source names in character 
array C__SOURCE[N__SOURCE].

.ti -4
LIST /TELESCOPE

List the telescopes in the current index. The number of 
different telescopes is in variable N__TELESCOPE, the telescope names in character 
array C__TELESCOPE[N__TELESCOPE].

.ti -4
LIST /OFFSET 

List the observed position offsets for the current index.

.ti -4
LIST /VARIABLE var__list 

List the value of the header variables given in var__list.  These
variables must have been defined by command VARIABLE. If "/FORMAT
format__list" is also given, each variable in the list is printed
according to the associated format item. The format items must match
the variable types. With option /SHORT, a line is printed only if at
least one of the variables has changed, and is preceded by the
corresponding scan number range.

Example: LIST /VARIABLE FREQUENCY IFCEN[2] /FORMAT f10.3 f6.3 /SHORT
gives the sky rest frequency and the central IF frequency of subband
L02, as a function of scan numbers. These variables must have been
previoulsy defined using VARIABLE RF and VARIABLE LINE.

.ti -4
LIST /BANDPASS

List the bandpass solutions stored as scan in the input file.


.in -4

.ti -4
1 MARK
.ti +4
CLIC\MARK f1 f2 ...  [/ANTENNA i ][/BASELINE ij] [/RESET]

Set the antenna or baseline mark words.

To decide whether data should be used, CLIC uses the logical OR  of
the  data  flag words with the corresponding mark words.  Thus data from
some subbands may be [temporarily] ignored even if unflagged.  Flags may
be  relative  to  antennas  or baselines.  /ANTENNA or /BASELINE must be
given, with antenna numbers or baseline  names  as  arguments.   Several
antennas and baselines may be given simultaneously.  Use /ANTENNA ALL or
/BASELINE ALL for all antennas or all baselines.

Flag names f1 f2 ...  are  alphanumeric  codes.   Valid  codes  are
subband  names  (C01  to C136, L01 to L136), DATA, POINTING, SHADOW, TSYS,
SATURATION and LOCK and REDU

Use option /RESET to reset flags that were accidentally set in  the
mark words.

MARK with no arguments (just options)  will  list  the  MARK  words
currently in use. See also STORE FLAG /MEMORY if you want to flag a subset
of scans in memory.

.ti -4
1 MASK
.ti +4
CLIC\MASK f1 f2 ...  [/ANTENNA i1 [...]] [/BASELINE  b1 [...]] 
.ti +4
[/RESET] [/ALL] [/SPECTRAL]

This command causes some flags to be ignored by setting the antenna or
baseline "mask" words. Data flagged will normally not be processed by
calibration commands. However flags set in the corresponding mask word
will be ignored, causing data to be processed anyway. Flags may be
relative to antennas or baselines. One of the options /ANTENNA or
/BASELINE must therefore be given, with antenna numbers or baseline
names as arguments.

Supported flag names are:

.nf
- C001 to C136 for bad individual continuum correlator subbands
- L001 to L136 for bad individual spectral correlator subbands
- DATA for bad data
- TSYS for too high system temperature (antenna based only)
- LOCK for out of lock local oscillator (antenna based only)
- POINTING for poor pointing (antenna based only)
- SHADOW for antenna being shadowed by another antenna (ant. based only)
- SATURATION for too high total power on a particular antenna
- TIME for time discontinuity
- DOPPLER for doppler discontinuity
- REDU for data reduction 
.fi

Option /ALL will mask all flags.

Option /SPECTRAL will mask the spectral flag (C001 to C136 and L001 to L136)

Use option /RESET to remove flags from the mask works.

MASK with no arguments will list the mask words currently in use.

.ti -4
1 MINMAX
.ti +4
CLIC\MINMAX

This command is used to compute extremal amplitudes on the current
observation (loaded e.g. with GET). It processes all continuum and
line data, USB and LSB.  Results for the continuum subbands are stored
in variables C__MAXAMP__U, C__MINAMP__U, C__MAXAMP__L, C__MINAMP__L,
and results for the line subbanbds in variables L__*.

This command may be used in a MODIFY DATA or MODIFY RECORD loop, to
search for bad data.

.ti -4
1 MONITOR
.ti +4
CLIC\MONITOR delta__time

This command is used to prepare the atmospheric phase correction based
on the total power monitor (normally done at 1.3 mm). It process all
scans in the current index and performs two operations.

First, it processes the calibration scans to compute the correction
factors. i.e. the change of path length for a given change in emission
temperature of the atmosphere at the atmospheric monitor frequency
(normally 1.3 mm, i.e. using Receiver 2 data). These correction
factors are then written in subsequent scans, until a new calibration
is found.

Second, the scans in the current index are grouped in intervals of
maximum duration `delta__time' (in seconds); source changes will also
be used to separate intervals. In each interval a straight line is
fitted in the variation of atmospheric emission as a function of time;
this line will be the reference value for the atmospheric correction,
i.e. the correction at time t is proportional to the difference
between the atmospheric emission at time t and the reference at time
t. This scheme is used to avoid contaminating the correction with
total power drifts of non-atmospheric origin (changes in receiver
noise and gain, and changes in ground noise).

MONITOR 0 will use for each scan the average of the atmospheric
emission as the reference value. This will cause the correction to
average to zero in one scan: the average phase is not changed, only
the coherence is restored leading to an improved amplitude (this is
what is done in the correlator at the Plateau de Bure to compute the
scan-averaged spectral and continuum quantities).


.ti -4
1 MODIFY
.ti +4
CLIC\MODIFY Item [Values...] 

This is a command to change some parameters relevant to data
acquisition, such as baseline values, time, position of phase center,
delay, etc. MODIFY applies to the current index. An output file must
be opened (it may be equal to the input file).

Note the special behaviour of MODIFY HEADER, MODIFY DATA, and MODIFY
RECORD, which execute an external script to modify the data and/or the
header, hence giving to the user a large flexibility in the possible
changes.

The MODIFY command is to be used with great caution, as it can
directly affect the data. There's no telling what can happen if this
command is wrongly used. So please consult an expert before any
action.

.ti -4
2 ANTENNA
.ti +4
CLIC\MODIFY ANTENNA a1 x1 y1 z1 [a2 x2 y2 z2 ...] [/OFFSET 89|96|99]
.ti +4
CLIC\MODIFY ANTENNA FITTED

Modify the vector coordinates for antenna a1 to be: x1, y1, z1
(meters), and the phases accordingly.  Keyword FITTED will load the
antenna coordinates the most recenty found by the SOLVE BASELINE
command.

Option /OFFSET 86|96|99 allows to select to which version of the
"standard" antenna coordinates the offset reffer.

.ti -4
2 AXES__OFFSET
.ti +4
CLIC\MODIFY AXES__OFFSET a1 x1 [a2 x2 ...]

Correct the phases for the offset of the elevation axis with respect
to the azimuth axis. This effect, if different for different antennas,
causes a phase offset proportional to frequency and to the cosine of
elevation.  a1 is the antenna number, x1 the offset between axes in
meters.  The actual values should be at most 1 mm, and may be measured
using the command SOLVE BASELINE, using SET X ELEVATION in addition to
Hour angle and declination.

.ti -4
2 BASELINE
.ti +4
CLIC\MODIFY BASELINE b1 x1 y1 z1 [b2 x2 y2 z2 ...] [/OFFSET 89|96|99]
.ti +4
CLIC\MODIFY BASELINE FITTED

Modify the vector coordinates for baseline b1 to be:   x1,  y1,  z1
(meters),  and  the  phases  accordingly.   Keyword FITTED will load the
baseline coordinates the  most  recenty  found  by  the  SOLVE  BASELINE
command.

Option /OFFSET 86|96|99 allows to select to which version of the
"standard" antenna coordinates the offset reffer.

.ti -4
2 BUG               
.ti +4
CLIC\MODIFY BUG number

This command is reserved for the correction of nasty bugs in the data
acquisition.  The number is used for identification.

Current accepted values:

.in +4 
.ti -2 
1 Affecting data taken between 11-nov-1995 and 09-jan-1996.  Bug in
RDI found by S.Guilloteau. The continuum data was erroneously
calibrated in the real-time aquisition. As result, the continuum data
did not agree with the average of the spectral data.  For instance
plotting data with "set sub C02 L02" as a function of time gives
different results for C02 and L02. The result would affect line
intensities if, as is usually the case, the amplitude calibration is
done with the continuum subbands.

Correction:
the current index should contain both atmosphere calibrations and 
correlation data; the data file should be open for both input and output.
This command should not affect data taken before 11-nov-1995 and after
09-jan-1996; be careful for the last day since the hour is not checked, 
and RDI was corrected at 3pm.

.ti -2
2 Affecting data taken between 26-jan-2015 and 05-mar-2015. Bug in correl
after change of commons to 7 antennas. Consequence is a phase offset between
narrow band correlator units and widex units depending on elevation and
baseline.

MODIFY BUG 2 will correct the bug. Warning: this correction is an offset to
the phases, so it should be applied only once. If the correction is done on 
data file (IPB), there is a check that this is the case, but header files (HPB) 
are not protected against correcting twice.

.ti -2
3 Affects data reduced with a CLIC version compiled from 15-jun-2023 to 
19-oct-2023, if HR spw are present and any MODIFY (ANTENNA, BASE, DELAY ...)
was done in lowres mode. In that case, CLIC stored data modifiers only for
the low-resolution spectral windows.

MODIFY BUG 3 will check the data modifier from both LR and HR, and if they
do not match will apply the complement of LR to HR.

.in -4

.ti -4
2 CABLE    
.ti +4
CLIC\MODIFY CABLE arguments

Modify the cable phase. 

MODIFY CABLE a1 a2 a3 a4 a5 a6 corrects for a permutation of the cables
to the phasemeters. Phasemeters 1 2 3 4 5 6 are assumed to be connected
to the antennas a1 a2 a3 a4 a5 a6.

MODIFY CABLE CONTINUOUS corrects the cable phases to be continuous
(should use only the correlations, without LOCK flag, for which the 
phases have a meaning).

MODIFY CABLE FACTOR f asssume the phase correction applied  has to 
be multiplied by f (replaces the old MODIFY CABL2).

.ti -4
2 DELAY
.ti +4
CLIC\MODIFY DELAY a1 d1  [a2 d2 ...] [/OFFSET] [/IF if] [/BBAND ib] [/ALL]
[/INSTRUMENTAL] [/POLARISATION H|V|BOTH] [/SWITCH DIRECT|CROSSED]

Modify the delay for  antenna  a1  to  be d1 (nanoseconds),
and  recompute the  phases  accordingly. 

Use option /OFFSET to enter delay changes with respect to the 
previous values.

Option /IF or /BBAND allow to modify the delay for a given IF or baseband. 
Option /ALL modify all spectral windows.

Option /INSTRUMENTAL allows to correct a delay that would have been introduced
in the system after mixing with LO1, i.e. in IF1.

Option /SWITCH allows to correct only baselines where the antennas are in
the direct/crossed state.

.ti -4
2 DOPPLER
.ti +4
CLIC\MODIFY DOPPLER

Computes the Doppler velocity correction, in case it was not  taken
into  account at the time of observing.  The LO2 frequency in the header
is assumed to be the frequency actually used.  A warning  is  issued  if
the  LO1  frequency in the header is not coherent with the LO2 frequency
(which means the phase tracking might be in error, since  it  uses  that
LO1 frequency).

The frequencies and line names introduced by SET FREQUENCY are used
to define the velocity scales for each subband/sideband.

.ti -4
2 FLUX
.ti +4
CLIC\MODIFY FLUX value

Modify the flux of the source as stored in the header.  In SET
AMPLITUDE SCALED mode, the amplitude will be divided by this number
before plotting.

.ti -4
2 SPIDX
.ti +4
CLIC\MODIFY SPIDX value

Modify the spectral index of the source as stored in the header.  In SET
SPIDX ON mode, the amplitude be corrected by this spectral index with 
respect to reference frequency.

.ti -4
2 FOCUS
.ti +4
CLIC\MODIFY FOCUS [antenna1 value1 antenna2 value2 ...]

Correct the phases for the offsets in focus, introduced to optimize
efficiency. antenna1 is the antenna number, value1 the focus offset in
mm, and so on.  The phases are normally corrected in real time since
1996-nov-29.  Between 1996-may-29 and 1996-nov-29, the focus
corrections were logged in the data files. Before 1996-may-29 they are
only in the log-obs files. Between 1996-nov-29 and 1998-apr-02, the
correction had wrong sign for the few projects using HIGH LOCK.

So use MODIFY FOCUS with NO arguments for data more recent that
1996-nov-29: this should correct the HIGH LOCK problem.  Between
1996-may-29 and 1996-nov-29, MODIFY FOCUS with no arguments will use
the focus offsets in the header and apply the corresponding phase
offsets.

For older data you may now search for the focus changes in the log
files to apply the phase corrections before calibration; or use jumps
in the phase calibration (SOLVE PHASE /BREAK) just as you had done
before.

.ti -4
2 FREQUENCIES
.ti +4
CLIC\MODIFY FREQUENCIES

The frequencies and line names introduced by SET FREQUENCY are used
to re-define the  velocity scales  for each subband/sideband. By default,
the frequency and line name entered in OBS for  at data aquisition on the 
Plateau de Bure is used for all sidebands and subbands. 

.ti -4
2 SIGN__PHASE
.ti +4
CLIC\MODIFY SIGN__PHASE

Change the sign of all phases of the data in the current index.
This command is intended for recovering data taken in a preliminary
status of the new correlator software.

.ti -4
2 PHASE
.ti +4
CLIC\MODIFY PHASE  a1 p1  [a2 p2 ...] [/IF if] [/BBAND ib] [/ALL]
[/POLARISATION H|V|BOTH] [/SWITCH DIRECT|CROSSED]

Modify the visibility phase for antenna a1 by d1 (unit determined
from SET PHASE DEGREE|RADIANS).

Option /IF or /BBAND allow to modify the delay for a given IF or baseband. 
Option /ALL modify all spectral windows.

Option /SWITCH allows to correct only baselines where the antennas are in
the direct/crossed state.


.ti -4
2 POSITION
.ti +4
CLIC\MODIFY POSITION EQ Epoch R.A. Dec.

Modify the source (phase center) position. This precesses the phases
accordingly. Note that this cannot change the antenna pointing center.
Typical use of this command is to correct positions of inaccurate
phase calibrators.

.ti -4
2 REFERENCE
.ti +4
CLIC\MODIFY REFERENCE UPPER|LOWER r1 r2 ...

The reference channels in the available line subbands  are  changed
to the new values.  Use with caution:  this command is actually changing
the frequency and velocity scale of your data.

.ti -4
2 SCALE
.ti +4
CLIC\MODIFY SCALE amplitude phase

Multiply all data in the current index by this (complex) scale
factor. To be used in case of emergency only!. Phase is interpreted
according to the SET PHASE command (radians or degrees).

.ti -4
2 TELESCOPE
.ti +4
CLIC\MODIFY TELESCOPE

Compute the telescope name (i.e. the configuration name) according to
the new rules.

.ti -4
2 TIME
.ti +4
CLIC\MODIFY TIME dut1

Modify the time constant DUT1 (in seconds) and recompute the phases
accordingly. For very high accuracy astrometry, DUT1 may need to be
adjusted afterwards to correct for irregularities for the earth
rotation. The "a priori" estimates may be wrong.  Another case is the
leap seconds, if they are introduced asynchronously with the DUT1
constant...

.ti -4
2 VELOCITY
.ti +4
CLIC\MODIFY VELOCITY New__vel

The source velocity is changed to New__vel. Use with caution: this
command is actually changing the frequency and velocity scale of your
data.

.ti -4
2 HEADER
.ti +4
CLIC\MODIFY HEADER procedure

This is a general command to edit the header of the scans in the
current index..  CLIC enters a loop in which all the headers are read
successively.  For each header the procedure 'procedure' (default
extension ".clic") is executed.  This procedure may only contain the
following commands : DUMP, HEADER, GO, or any SIC command that acts on
variables. Especially, variables defined by the VARIABLE command can
be modified...

The command GO [WRITE] must end the procedure.  With GO WRITE, the
scan header will be updated; with only GO, the scan header is not
updated and CLIC loads the next scan header in the current index.  If
no GO command in encountered in the procedure, the loop is aborted.
If a PAUSE command is found in the procedure, the PAUSE is executed,
but the prompt changes to "MODIFY>".  The same commands as above may
then be executed from the keyboard; "QUIT ALL" may be used to abort
the loop.

.ti -4
2 DATA
.ti +4
CLIC\MODIFY DATA procedure [/BEFORE date] [/AFTER date] [/ATM]

This is a general command to edit the data headers of the scans in the
current index. CLIC enters a loop in which for all scans in the
current index, the data header of the average record is read. For each
scan the procedure 'procedure' (default extension ".clic") is
executed. This procedure may only contain the following commands :
DUMP, HEADER, FLAG, MINMAX, GO, or any SIC command that acts on
variables. Especially, variables defined by the VARIABLE command can
be modified...

The command GO [WRITE] must end the procedure.  With GO WRITE, the
data record will be updated; with only GO, the data record is not
updated and CLIC loads the next record from the current index.  If no
GO command in excountered in the procedure, the loop is aborted.
If a PAUSE command is found in the procedure, the PAUSE is executed,
but the prompt changes to "MODIFY>".  The same commands as above may
then be executed from the keyboard; "QUIT ALL" may be used to abort
the loop.

The options /BEFORE and /AFTER allows to select data depending on
their observing dates.

If present, the /ATM option allows to modify the data header of
the phase corrected average record (will work only if such record
is present in the data, so only on cross-correlations: CROSS, 
FLUX, POINT, GAIN ...)

.ti -4
2 RECORD
.ti +4
CLIC\MODIFY RECORD procedure [/RECORD idump] [/BEFORE date] [/AFTER date]

This is a general command to edit the data headers of the scans in the
current index.  CLIC enters a loop in which all the data header of all
records of all scans in the current index are read successively.  In
the case the option "/RECORD idump" is used, only the record number
idump is read.  For each record the procedure 'procedure' (default
extension ".clic") is executed.  This procedure may only contain the
following commands : DUMP, HEADER, FLAG, MINMAX, GO, or any SIC
command that acts on variables. Especially, variables defined by the
VARIABLE command can be modified...

The command GO [WRITE] must end the procedure.  With GO WRITE, the
data record will be updated; with only GO, the data record is not
updated and CLIC loads the next record from the current index.  If no
GO command in excountered in the procedure, the loop is aborted.  If a
PAUSE command is found in the procedure, the PAUSE is executed, but
the prompt changes to "MODIFY>".  The same commands as above may then
be executed from the keyboard; "QUIT ALL" may be used to abort the
loop.

The options /BEFORE and /AFTER allows to select data depending on
their observing dates.

.ti -4
1 NEW__DATA
.ti +4
CLIC\NEW__DATA [time] [tries]

Waits until new data has been written to the input file, then
makes a new index from all new data. The type of observation can be
changed by this command, but the index will contain only observations
of one type. Selection criteria defined by command SET are ignored.

This command can be used to make a quick look or analysis of data
produced by a real time acquisition system (Plateau de Bure).
Caution: only two programs should access the input file
simultaneously, one for writing the other for reading.

The first argument is the time interval between two consecutive
inspections of the file index; the second is the allowed number of
unsuccessful attempts to find new data in the file. The defaults are
10 seconds and 12 tries (two-minute timeout).

.ti -4
1 PLOT
.ti +4
CLIC\PLOT keyword [/IDENTIFY [COLOUR]] [/NOFRAME [pen]] [/NODRAW] 
.ti +4 
[/RECORD list__of__records] [/RESET] [/APPEND] [/PHYSICAL]
.ti +4 
[/BOXES nx ny] [/NOSORT]

Plot data from the current index according to options selected by
the CLIC\SET command. 

.in +4
.ti -4
PLOT [ALL]

Erases the screen and plots all data in the current index (default).

.ti -4
PLOT FIRST

Erases the screen and plots data from the first observation in the
current index.

.ti -4
PLOT NEXT 

Plots data from the next observation in the current index. Does not
clear the screen before plotting.

.ti -4
PLOT number 

Plots data from the observation of the given number (must be in the
current index). Does not clear the screen before plotting.

.ti -4
PLOT SAME

Plots again the last plotted buffers (with possibly new options, such
as line type, limits, ...).

.ti -4
PLOT /NOFRAME [Pen]

Does not erase the screen, and plots data in the present boxes,
optionally with a new pen. This is very useful for comparing data. It
can also be used in conjunction with PLOT /APPEND.

.ti -4
PLOT /NODRAW 

Does not produce the plot but read all data and update the X__DATA and
Y__DATA buffers. This is very useful to e.g. modify these buffers in
SIC before actual plotting (with PLOT SAME).

.ti -4
PLOT /RECORD list__of__records

Plots only some records for the observation(s). "list__of__records" is
of the format n1 to n2 n3 n4 to n5, as with the SIC\FOR command.

.ti -4
PLOT /IDENTIFY [COLOR]

Plots a different GREG symbol for each source (if SET PLOT POINT is
currently active). Using optional argument COLOR will produce points
also differing by color.

.ti -4
PLOT /NOSORT

Prevent sorting of data according to X axis in each box.

.ti -4
PLOT /PHYSICAL

Plot labels use physical antenna number rather than logical numbers. 

.ti -4
PLOT /BOX nx ny

Plot page will be arranged with nx times ny boxes. Wildcard may be used. 

.ti -4
PLOT /RESET

Reset the time origin (and, by consequence, the time-dependent
amplitude and phase calibration curves) before plotting.

.ti -4
PLOT /APPEND

Does not reset the previous buffers before reading data and plotting.
This may be used at the Plateau de Bure for incrementally plotting new
data just after it is written on disk.
.in -4

After the plot, the arrays X__DATA[N__DATA,N__BOXES] and 
Y__DATA[N__DATA,N__BOXES] 
contain the values of the points that have been displayed. N__BOXES is 
the number of boxes that have been plotted, and N__DATA[N__BOXES] is the 
number of data points in each box. W__DATA[N__DATA,N__BOXES] contains the
weights associated to each data point.

.ti -4
1 POPUP
.ti +4
CLIC\POPUP

Interactive display helper: use the graphic cursor to point to a plotted box,
and CLIC will redraw that box in a temporary window. Press 'E' to exit.

.ti -4
1 PRINT
.ti +4
CLIC\PRINT Item

Prepares a procedure for further use.

.in +4
.ti -4
PRINT BASELINE

Prepares a procedure to be used in OBS to enter the most recently
fitted baseline parameters (SOLVE BASELINE command). This procedure
also contains (but commented out) the CLIC\MODIFY command to edit
previous data to the same fitted baseline parameters.

.ti -4
PRINT DELAY

Prepares a procedure to be used in OBS to enter the most recently
fitted delay parameters (SOLVE DELAY command).

.ti -4
PRINT FLUXES

Prepares a procedure to be  used in CLIC to re-enter  the  most
recently determined source fluxes (SOLVE FLUX command).
.in -4

.ti -4
1 RESIDUALS
.ti +4
CLIC\RESIDUALS item

Clear the graphic screen and plot the  residuals  from  last  SOLVE
command. "item" can only be "BASELINE" up to now.

.ti -4
1 SAVE
.ti +4
CLIC\SAVE name

[STILL UNIMPLEMENTED]

SAVE creates a procedure file of name "name.clic", containing all the
current parameters of the program.  This file may be executed at any
time using the @ command : just type "@ name" after the CLIC>
prompt, or pass "@ name" as a parameter when invoking CLIC (by typing
"CLIC @ name").  This file is composed of standard CLIC commands, and
may be edited with any text editor.

.ti -4
1 SET
.ti +4
CLIC\SET Keyword [Value1 [Value2 [...]]] [/DEFAULT] 

This command is used to specify a value for a parameter used by CLIC.
These values may be temporarily overridden by the options of some
commands (e.g. FIND). 

Each "SET Keyword" command has an equivalent "SHOW Keyword" command
that display the current status. SET /DEFAULT restores all default
values.

.ti -4
2 AMPLITUDE
.ti +4
CLIC\SET AMPLITUDE [ABSOLUTE|RELATIVE] [SCALED|UNSCALED] 
.ti +4
[KELVIN|JANSKY] [ANTENNA|BASELINE] [RAW] [SIZED|UNSIZED]
.ti +4
[SPIDX|NOSPIDX]

This command controls which scaling factor is applied to the data for
plotting and writing in the output table, in subsequent PLOT and TABLE
commands:

.in +4
.ti -2
- ABSOLUTE means that the relative amplitude calibration is not
applied.

.ti -2
- RELATIVE means that the relative amplitude calibration, as
determined with SOLVE AMPLITUDE, and stored with STORE AMPLITUDE, is
applied.

.ti -2
- SCALED means that the absolute amplitude is divided by the source
flux; SCALED is only used for the command SOLVE AMPLITUDE.

.ti -2 
- KELVIN|JANSKY indicates the unit in which the amplitude are
displayed: either Kelvins (in main-beam brightness temperature) or
Janskys.
.in -4

SET AMPLITUDE ABSOLUTE forces SET AMPLITUDE KELVIN since the
uncalibrated data are measured in Kelvins. With SET AMPLITUDE
RELATIVE, the amplitudes are in Janskys, since a calibrator of known
flux has been used for reference. If the default is overridden (SET
AMPLITUDE ABSOLUTE JANSKY or SET AMPLITUDE RELATIVE KELVIN),
conversion factors (=antenna efficiencies) are taken from the scan
headers; these factors may be determined by SOLVE FLUX and stored by
STORE FLUX.

SET AMPLITUDE ANTENNA|BASELINE switches between Antenna-based and
Baseline-based amplitude calibrations.  This switch will be active for
SOLVE AMPLITUDE (calibration curve determination), STORE AMPLITUDE
(calibration curve storing operation), and SET AMPLITUDE RELATIVE
(application). Both baseline-based and antenna-based calibration
curves may be stored alongside in the data header, independently of
each other. Using SET AMPLITUDE ANTENNA is recommended.

SET AMPLITUDE RAW allows to plot the amplitude as correlation coefficient
by dividing the amplitudes by the geometrical average of system temperatures
of the antennas consisting the considered baseline.

SET AMPLITUDE SIZED|UNSIZED switches on and off a correction of the
amplitude for source size (sources with known size are W3OH and MWC349).

SET AMPLITUDE SPIDX|NOSPIDX switches on and off a correction of the
amplitude for the source spectral index (w.r.t. the reference frequency).

.ti -4
2 ANGLE
.ti +4
CLIC\SET ANGLE unit

Specify the angle unit for offsets.  May be R[adian], D[egree],
M[inute of arc], S[econd of arc].  Default is SECOND.  The ANGLE unit
is also used to display Continuum drifts.

.ti -4
2 ANTENNAS
.ti +4
CLIC\SET ANTENNAS [a1 a2 ...]
.ti +4
CLIC\SET ANTENNAS [ALL] [PHYSICAL]|[LOGICAL]

Selects the antennas for which data will be displayed by command
PLOT. This command is exclusive with commands SET BASELINES and SET
TRIANGLES.

Parameters which may be displayed in this antenna-mode are obvious
antenna-based parameters such as cable phase, LO-phase and rate, ...
With SET Y AMPLITUDE and when more than 3 antennas are available in
the data, antenna amplitude is computed by averaging all possible
"triangular ratios" of baseline amplitudes. With SET Y PHASE a phase
is attributed to each antenna by setting the phase of antenna 1 to
zero, and making use of closure relations for other antennas (least
square fit). This is useful for fitting baselines for instance (it
enables one to determine directly antenna position offsets).

SET ANTENNA with no arguments selects all antennas present in the
baselines previously in use. SET ANTENNA ALL will select all the
antennas available in the first scan of the current index, for each
command accessing the data (e.g. PLOT).  This is the default.

Note that SET ANTENNA also allows to select the antenna to be
processed by the SOLVE HOLOGRAPHY command (if several antennas are
selected, the first one in the list is processed).

SET ANTENNA PHYSICAL|LOGICAL allows to select if the antenna numbers are
to be interpreted as physical (i.e. antenna ID) or logical (rank of the
antenna in the ordered list of antenna physical number available
in the observation). The antenna numbering in the header of boxes in the
PLOT will change according to this switch.

.ti -4
2 APC
.ti +4
CLIC\SET APC status

*** THIS COMMAND IS OBSOLETE ***

.ti -4
2 AVERAGING
.ti +4
CLIC\SET AVERAGING mode

Selects time averaging of data plotted (the data in the file is
unaffected). 'mode' may be :

.in +4
.ti -2
- NONE :  all data points are plotted.

.ti -2
- SCAN :  the scan-averaged data is used and only one point is
thus plotted per scan.

.ti -2
- TIME dt :  data is averaged in  time  intervals  of  length  dt
(seconds).  Data of consecutive scans is NOT averaged together.

.ti -2
- METHOD VECTOR : complex visibilities are averaged as complex
numbers.

.ti -2
- METHOD SCALAR : amplitude and phases of visibilities are
averaged separately.

.ti -2
- CONT : sideband averages are computed on continuum subbands.

.ti -2
- LINE : sideband averages are computed on line subbands. Baseband 
averages are derived from the IF averages.

.in -4

This command obviously does not affect the spectral data. See also
SET BINNING for another way of averaging data.

.ti -4
2 ASPECT__RATIO
.ti +4
CLIC\SET ASPECT__RATIO value [AUTO|EXACT]

Choose a default aspect ratio (x__size/y__size) for boxes plotted  by
command  PLOT.  If several boxes must be plotted (depending on subbands,
baselines, or sidebands selected), the plot page will be partitioned in
order to:

.in +4
.ti -2
- AUTO mode:  approach this aspect ratio for each box while filling
the whole page.

.ti -2
- EXACT mode:  use this aspect ratio for each box (part of the plot
page will be left blank).
.in -4

The default is 2.0 AUTO.

.ti -4
2 ATMOSPHERE
.ti +4
CLIC\SET ATMOSPHERE Argument Value /ANTENNA a1 [a2 ...]

Selects the way atmospheric calibration is done by command ATMOSPHERE,
Argument may be FILE, AUTO, TREC, or MANUAL. This will affect the
antennas given in argument to the option /ANTENNA (/ANTENNA ALL
selects all antennas). Argument may also be NEW, 2009, 2003, OLD, 1985, to
switch between atmospheric model versions or INTERPOLATE to use tabulated
atmospheric model (defined to be GAG__ATMOSPHERE) ; option /ANTENNA is not
required in that case.

.in +4
.ti -2
- In FILE mode the actual mode is taken from the data header,  as
given in the OBS program.

.ti -2
- In TREC mode the receiver temperature is assumed known, to set the
scale of measured sky temperature and optical depth, and determine the
system noise temperature.  The receiver temperature is taken from the
data header, as given in OBS.  It may be forced to a different value
by giving it as second argument 'value', or by the SET TREC command.

.ti -2
- In AUTO mode the water wapor content is assumed  known;  it  is
determined  from  the  antennas  in TREC mode, if any, or taken
from the data header, or forced  to  the  value  given  in  the
second argument 'value', or by the SET WATER command.

.in -4
These parameters, together with the wheather station data, are  used  to
compute  the system noise temperature for each antenna.  In MANUAL mode,
no model atmosphere is used,  but  the  values  of  optical  depths  and
atmospheric temperatures stored in the data.

.in +4 
.ti -2 
- OLD or 1985 select the old ATM model, in use at IRAM since circa
1985.

.ti -2 
- 2003 select the 2003 version of the ATM model,developed by Juan Pardo in ISM in Madrid. For this, the new ATM library must be available. If not the old ATM  will be used.

.ti -2 
- NEW or 2009 (the default) select the 2009 ATM model,developed by
Juan Pardo in ISM in Madrid. For this, the ATM library must be
available. If not the old ATM will be used.

.ti -2 
- INTERPOLATE will use a tabulated file produced by ASTRO\ATMOSPHERE MAKE. This option should not be used, as the use of tabulated file is only used to speed 
up calculations at Bure.


.in -4

.ti -4
2 BANDS
.ti +4
CLIC\SET BANDS b1 b2 ...

Selects the sidebands for which data will be displayed by command
PLOT.  Valid codes are "UPPER" or "USB", "LOWER" or "LSB", "AVERAGE"
or "DSB", "DIFFERENCE", and "RATIO".  

In "AVERAGE", "DIFFERENCE" or "RATIO" modes, the sidebands
visibilities are corrected before combination for their relative
phases, as determined by the RF bandpass calibration.  If no RF
bandpass calibration is available (i.e. stored with the data), the
relative phases are obtained by averaging the continuum subbands
(which is useless if no continuum emission is detected).

.ti -4
2 BASELINES
.ti +4
CLIC\SET BASELINES [b1 b2 ...]
.ti +4
CLIC\SET BASELINES [ALL]  [PHYSICAL]|[LOGICAL]

Selects the baselines for which data will be displayed by command
PLOT.  Valid codes are pairs of antennas, e.g. "01-02", "01-03", "09-10",
etc...  This command is exclusive with commands SET ANTENNAS and SET
TRIANGLES.

SET BASELINE with no argument selects all baselines connecting the
antennas previously in use. SET BASELINE ALL will select all the
baselines available in the first scan of the current index, for each
command accessing the data (e.g. PLOT).  This is the default.

SET BASELINE PHYSICAL|LOGICAL allows to select if the baseline numbers are
to be interpreted as physical (i.e. antenna ID) or logical (rank of the
antenna in the ordered list of antenna physical number available
in the observation). The baseline numbering in the header of boxes in the
PLOT will change according to this switch.


.ti -4
2 BINNING
.ti +4
CLIC\SET BINNING size [position]
.ti +4
CLIC\SET BINNING OFF

Selects data averaging in bins of the parameter in the X coordinate
array.  Bins are defined by the size of intervals, and the position of
one of the intervals (in units of the X coordinate; default is 0).  SET
BINNING OFF will turn this mode off. Note that this averaging in bins
occurs AFTER the averaging selected by SET AVERAGING.

SET BINNING is particularly useful for averaging spectra along the
frequency axis and for plotting data as a function of UV coordinates.

A command SET X used to change the X units will automatically reset the 
binning OFF.

.ti -4
2 BPC
.ti +4
CLIC\SET BPC status

FIND will select observations according to the status of RF Bandpass
Calibration (BPC). 'status' may be YES to select observations already
calibrated, NO to select still uncalibrated observations, * to
disregard this selection criterion. This command is very seldom used.

.ti -4
2 CLOSURE
.ti +4
CLIC\SET CLOSURE b1 w1 b2 w2 ...

*** THIS COMMAND IS OBSOLETE ***

Select weights to be used for each baseline when computing the closure
relations (this  is  done  by  a  least  squares  resolution  of  an
overdetermined system, in antenna mode).  You  may  wish  to  give  more
weight to the shorter baselines.  Default weights are equal.

.ti -4
2 CRITERIA
.ti +4
CLIC\SET CRITERIA /DEFAULT

Reset all the search criteria for command FIND to their default
values (all the observations in the file will be found). Use SHOW
CRITERIA to list the current criteria.

SET /DEFAULT will set default values for all parameters (not 
only selection criteria).

.ti -4
2 DATA
.ti +4
CLIC\SET DATA np nb

Extend the size of the plot buffers to contain nb boxes of np
points each. 

.ti -4
2 DEFAULT 
.ti +4
CLIC\SET DEFAULT (or SET /DEFAULT)

Reset all the SET parameters to their default values.

.ti -4
2 DROP
.ti +4
CLIC\SET DROP low high

Give the fraction of the passband to be left out at the low-frequency
and at the high frequency ends of each spectral correlator
subband. This is used by further PLOT and TABLE commands.  The default
is 5% of the bandwidth at both ends.

.ti -4
2 ERRORS
.ti +4
CLIC\SET ERROR NOISE|ATMOSPHERE

Controls the way the error bars for phase plots in time mode are
computed.
.in +4
.ti -2
- with NOISE the errors are computed according to the system noise
only; this is the default.  
.ti -2
- with ATMOSPHERE the rms phase fluctuations as measured when
compressing the data, are included in the error bars.
.in -4

.ti -4
2 EXTENSION
.ti +4
CLIC\SET EXTENSION string

Use 'string' as the list of the default extensions for the FILE IN 
command. The default is ".hpb .ipb" (in this order).    

Not all extensions are accepted by CLIC: other possible values are
".ipb-raw", ".ipb-comp", ".ipb-cal", ".ipb-data".

.ti -4
2 FINDPOL
.ti +4
CLIC\SET FINDPOL i1 [i2] ... [i17]| *

Set which polarisation subscans FIND will search. 0 means direct, 1 all
crossed. * deactivates the search on polarisation subscans.

.ti -4
2 FLUX
.ti +4
CLIC\SET FLUX name value [frequency] [date] [/RESET]

Enters `value' as the flux (in Janskys) of source `name'.  

The flux of one or several reference sources must be given to CLIC as
an input to command SOLVE FLUX (which derives the antenna efficiencies
and the fluxes of the other objects).  If the flux of a source is
entered by SET FLUX, this source will be a reference source. After
"SET FLUX name *", source `name' will not be a reference source any
more. Its flux may then be re-determined by a subsequent SOLVE FLUX
command. 

Use command SHOW FLUX to list the fluxes known to the current CLIC
session. The reference sources are listed with a "FIXED" keyword
(their flux is fixed), while the flux determined by SOLVE FLUX are
listed as "FREE".

One may optionally enter a frequency (in GHz) and a date
(jj-mmm-yyyy).  The frequencies and dates are checked in that case by
SOLVE FLUX and STORE FLUX. Matching is within 1 GHz for frequencies
and 1 week for dates.

If /RESET is given, all entries with the given source name are deleted
from the flux list. SET FLUX ALL /RESET will empty the flux list.

.ti -4
2 SPIDX 
.ti +4
CLIC\SET SPIDX name value [frequency] [date] [/RESET]

Enters `value' as the spectral index of source `name'.  

The flux of one or several reference sources must be given to CLIC as
an input to command SOLVE SPIDX (which derives the antenna
efficiencies and the spectral indexes of the other objects).  If the
spectral index of a source is entered by SET SPIDX, this source will
be a reference source. After "SET SPIDX name *", source `name' will
not be a reference source any more. Its spectral index may then be
re-determined by a subsequent SOLVE SPIDX command.

Use command SHOW SPIDX to list the spectral indexes known to the
current CLIC session. The reference sources are listed with a "FIXED"
keyword (their spectral index is fixed), while the flux determined by
SOLVE SPIDX are listed as "FREE".

One may optionally enter a frequency (in GHz) and a date
(jj-mmm-yyyy).  The frequencies and dates are checked in that case by
SOLVE SPIDX and STORE SPIDX. Matching is within 1 GHz for frequencies
and 1 week for dates.

If /RESET is given, all entries with the given source name are deleted
from the flux list. SET SPIDX ALL /RESET will empty the spectral index
list.

.ti -4
2 FORMAT
.ti +4
CLIC\SET FORMAT Keyword [ON] [OFF]

Set the format of the header information listed with the LIST /LONG
command. Each keyword indicate whether certain informations are to be
written (ON) or not (OFF). If all Keyword are ON, then the same list
of information as with the command HEADER is obtained.

.nf
    General information line  (always written)
         Observation number 
         Scan number
         Project Id
         Source name
         Source type 
         Procedure name
         Interferometer configuration
         Date of observation
         UT of observation
         Hour angle

     Position information line	(keyword POSITION)
         RA or L : right ascension or longitude (or azimuth)
         DEC or B : declination or latitude (or elevation)
         Epoch if equatorial coordinates are used
         Offsets in current units
         Type of coordinate (Eq, Ga, Ho)
         Flux of the source 
 
     Quality information line (keyword QUALITY)
         Quality code
         Flag
         Receiver number
         Number of dump
         Azimuth
         Elevation
	
     Spectral line information line (keyword STATUS) 
         Line name
         Rest frequency
         eideband 
         Doppler correction
         Source velocity  
	 Quarter [for new receivers only]
	 Polarization [for new receivers only]
	 Narrow-band correlator input [for new receivers only]

     Correlator information, for each subband (keyword SPECTRAL)
         Logical name
         Width (MHz)
         Central IF (MHz)
         Physical unit

     Interferometer status, for each antenna (keyword INTERFERO)
         Antenna number
         Station

     Pointing & Focus correction, for each antenna (keywrod POINTING)
         Azimuth correction
         Elevation correction
         Focus correction 

     Calibration information, for each antenna (keyword CALIBRATION)
         Receiver temperature (K)
         Image rejection (dB)
         Water (mm)
         System temperature (Tsys)
.fi

.ti -4
2 FREQUENCY
.ti +4
CLIC\SET FREQUENCY subband sideband name freq
.ti +4
CLIC\SET FREQUENCY ALL name freq

Select the line name and frequency to be used to define the velocity
scale, for the given sub-band and sideband, by the commands MODIFY
FREQUENCY and MODIFY DOPPLER.

'subband' may be C for continuum or L01 to L08 for spectral correlator
subbands; 'sideband' must be either USB or LSB; 'name' is a (max.  12
character) mnemonic for the line name; 'freq' is the rest frequency in
MHz.  If the line name is '*', then the default frequency entered
prior to the observation will be used to compute the velocity scale
for the corresponding subband.

"SET FREQUENCY  ALL"  will  fill  in  the  given  frequency  for  all
subbands.

.ti -4
2 GAIN__IMAGE
.ti +4
CLIC\SET GAIN__IMAGE value /ANTENNA i|ALL

Give the value of the relative gain for the receiver image side
band, to be used by the command ATMOSPHERE. Use * instead of the value
to force the use of the numbers stored in the file.

.ti -4
2 GAIN__METHOD
.ti +4
CLIC\SET GAIN__METHOD OLD|NEW

Selects the method used to compute antenna-based gains from
baselines-based measured quantities. Default is OLD (older
but more robust method). 

OLD method: 'gain' for a antenna i is computed from three baselines
(Gi = Gij.Gik/Gjk). All possible "triangular ratios" including the
antenna i are computed and averaged (for the phase, only triangles
including the reference antenna are considered).

NEW method: 'ALMA' like method. Solves the linear system of equations
(for the amplitudes, solves the logarithms).

.ti -4
2 GIBBS
.ti +4
CLIC\SET GIBBS number

Give the number of channels to be masked on each side of the central
frequency, for the correlator subbands which are obtained by
juxtaposition of both sidebands of a common local oscillator.  Due to
the Gibbs effect, a few channels are corrupted by a contribution of
the image sideband of the first local oscillator, which may contain
signal if the source has continuum emission.  This is the case for the
320 MHz bands at the Plateau de Bure correlator, as well as the
160 and 80 MHz bands in some modes.

The GIBBS number is used by further PLOT and TABLE commands. The
default is 0, which is relevant for line sources with no continuum
emission.

.ti -4
2 HOUR__ANGLE
.ti +4
CLIC\SET HOUR__ANGLE begin end

FIND will select all observations with hour angles in the specified
range (in hours).  Default is * * (no selection by Hour Angle).

.ti -4
2 IC
.ti +4
CLIC\SET IC status

FIND will select observations according to the status of Instrumental
(Phase+Amplitude) Calibration (IC).  'status' may be YES to select
observations already calibrated, NO to select still uncalibrated
observations, * to disregard this selection criterion. This command
is very seldom used.

.ti -4
2 LEVEL
.ti +4
CLIC\SET LEVEL number

Set the threshold severity level (0-8) for messages to be output on
the terminal. The default value is 4.

With SET LEVEL 1, all messages will be displayed. With SET LEVEL 8,
only key messages will be displayed (this is useful during pipeline
processing).

.ti -4
2 LINE
.ti +4
CLIC\SET LINE name

FIND will select all observations according to the specified line name
(not case sensitive). Default is *.  A syntax like NAM* can be used
to find observations with line names beginning by NAM.

.ti -4
2 MODE
.ti +4
CLIC\SET MODE FULL|LOWRES

SET MODE LOWRES sets CLIC in a mode where only low-resolution data are read.
SET MODE FULL restores the "normal" mode. Work only for Polyfix data.


.ti -4
2 NARROW__INPUT
.ti +4
CLIC\SET NARROW__INPUT 0|1|2

*** THIS COMMAND IS OBSOLETE ***

Selects the narrow-band correlator input.
The command is now obsolete. Use SET BBANDS instead.

.ti -4
2 NUMBER
.ti +4
CLIC\SET NUMBER n1 n2

FIND will select all Observations with numbers between n1 and n2.
Default is * *.

.ti -4
2 OBSERVED
.ti +4
CLIC\SET OBSERVED d1 d2

FIND will select all observations with observing dates between d1 and
d2.  Default is * *. 

d1 and d2 are normally in explicit form (jj-mmm-yyyy) but internal day
numbers are also accepted, i.e. something like SET OBSERVED 'DOBS-1'
'DOBS+1' is possible (DOBS contains the date of observation in
internal format and is available after the command VARIABLE GENERAL
ON has been issued).

.ti -4
2 OFFSETS
.ti +4
CLIC\SET OFFSETS o1 o2

FIND will select all observations with offsets o1 and o2.  Default is
* *. This is very useful in case of mosaic osbervations, in order to
select a specific field (and e.g. create a UV table). See also
SET RANGE.

.ti -4
2 PHASE
.ti +4
CLIC\SET PHASE [ABSOLUTE|RELATIVE] [ANTENNA|BASELINE] 
.ti +4
[INTERNAL|EXTERNAL] [ATMOSPHERE|NOATMOSPHERE] [FILE|NOFILE] 
.ti +4
[WVR|NOWVR] [TOTAL|NOTOTAL] 
.ti +4
[DEGREES|RADIANS] [JUMPY|CONTINUOUS]

.in +4
.ti -4
CLIC\SET PHASE ABSOLUTE|RELATIVE

This command decides whether the phase calibration is applied or not
to the data for plotting and writing the final UV table, in subsequent
PLOT and TABLE commands. ABSOLUTE means do not use the phase calibration
determined by the SOLVE PHASE command, RELATIVE means apply it.

.ti -4
CLIC\SET PHASE INTERNAL|EXTERNAL

Switch between two modes of phase calibration. 

INTERNAL is the standard mode. In EXTERNAL mode the calibration curve
from another receiver may be used (as stored by STORE PHASE /RECEIVER
r); on the top of this a second order calibration curve may be
determined (using SOLVE PHASE) and stored as usual. This does not
erase any INTERNAL calibration curve previously stored. 

For example, using receiver 2:

SET PHASE INTERNAL RELATIVE: use the phase curve determined from
Rec. 2 only

SET PHASE EXTERNAL ABSOLUTE: use the phase curve from Rec. 1 only, as
stored with STORE PHASE /RECEIVER 1

SET PHASE EXTERNAL RELATIVE: use the phase curve from Rec 2,
determined on top of the phase curve Rec. 1, by using SOLVE
PHASE and STORE PHASE with SET PHASE EXTERNAL in effect.

SET PHASE INTERNAL  is recommended for Receiver 1,  SET PHASE EXTERNAL
for Receiver 2.

.ti -4
CLIC\SET PHASE ANTENNA|BASELINE

Switch between Antenna-based and Baseline-based phase
calibrations. This switch will be active for SOLVE PHASE (calibration
curve determination), STORE PHASE (calibration curve storing
operation), and SET PHASE RELATIVE (application).  Both baseline-based
and antenna-based calibration curves may be stored alongside in the
data header, independently of each other. SET PHASE ANTENNA is
recommended.

.ti -4
CLIC\SET PHASE ATMOSPHERE|NOATMOSPHERE

Force CLIC to use or not the real-time atmospheric phase
correction. The atmospheric phase correction is based on monitoring
the atmosphere water vapor emission using either the total power
measured by the 1.3 mm receivers or the 22 GHz water vapor
radiometers. It is applied in real-time to each dump before computing
the scan-averaged quantities (spectra and continuum); these are
further corrected for the average atmospheric phase, hence leading to
phases essentially not modified, but to improved amplitudes
(correction of the decorrelation). This phase-corrected scan-averaged
dump will be used by CLIC after SET PHASE ATM has been issued. 

The phase correction will NOT be used if it has been declared invalid
for a given scan, using the command STORE CORRECTION, except if SET
PHASE NOFILE is in effect. See these commands.

Note that the continuum 1 sec dumps are not corrected in real-time,
and are therefore not affected by the SET PHASE ATM command. To
avoid any confusion, SET PHASE ATM forces SET AVER SCAN.

.ti -4
CLIC\SET PHASE FILE|NOFILE

Turn ON of OFF the effect of the STORE CORRECTION command.

If SET PHASE ATMOSPHERE FILE, the information on the validity of the
phase correction declared by STORE CORRECTION will be used, and the
phase correction will thsu be done only on scans validated by STORE
CORRECTION.

If SET PHASE ATMOSPHERE NOFILE, this information will be bypassed, and
the phase correction will be done for all scans.

.ti -4
CLIC\SET PHASE WVR|NOWVR

Switch ON or OFF the off-line atmospheric phase correction based on
the WVR data. All data (individual as well as scan-averaged dumps)
are affected. It is necessary to have run the WVR command before.
SET PHASE WVR forces SET PHASE NOTOTAL.

.ti -4
CLIC\SET PHASE TOTAL|NOTOTAL

Switch ON or OFF the off-line atmospheric phase correction based on
the 1.3 mm total power monitoring. All data (individual as well as
scan-averaged dumps) are affected. It is necessary to have run the
MONITOR command before. SET PHASE TOTAL forces SET PHASE NOWVR.

.ti -4
CLIC\SET PHASE DEGREE|RADIANS

Select the unit in which the phases are plotted.

.ti -4
CLIC\SET PHASE JUMPY|CONTINUOUS n

Selects the way phases are determined.  With argument JUMPY no attempt
is made to suppress 2pi jumps: the determination is always [-pi,pi].
With argument "CONTINUOUS n", the phase jumps are limited to +/- pi,
that is the phase is always chosen in the range
[previous-pi,previous+pi], n being the number of points averaged
together to estimate the 'previous' phase (default is 1, higher values
are to be used in noisy cases).

.in -4

.ti -4
2 PLANET
.ti +4
CLIC\SET PLANET *|PRIMARY|FILE [filename]

Planet model to be used by the SOLVE FLUX command. 

.in +4
* = default (elliptical disc)

PRIMARY = same with primary beam attenuation

FILE filename : use data in file filename (must be cubic splines).
.in -4

.ti -4
2 PLOT
.ti +4
CLIC\SET PLOT LINE|POINTS|HISTOGRAM|BARS
.ti +4
CLIC\SET PLOT PHYSICAL|LOGICAL HEADER|IPB

Selects the way the data are displayed.  "type" stands for LINE,
POINTS, HISTOGRAM, or BARS. With POINTS, the current GreG marker, as
defined by the GREG\SET MARKER command, is used.  With BARS (valid
only for the visibility data, i.e. amplitude, phase, real, or
imaginary), 1-sigma error bars are drawn.

Can also force plotting physical antenna wiht SET PLOT PHYSICAL (can be
reverted with SET PLOT LOGICAL).

Normally, with SET PLOT IPB (default), CLIC looks for the data headers 
(stored in the IPB file) even if one plots parameters in the observation
(which is contained also contained in the .hpb file). SET PLOT HEADER allows
to bypass this check, but flags can be lost.

.ti -4
2 POLARIZATION
.ti +4
CLIC\SET POLARIZATION NO|HOR|VER|BOTH|EACH

Selects the polarization of the new receivers. HOR and VER refers to
the two polarization channels (but the 'horizontal' or 'vertical'
definition is arbitrary). BOTH means that both polarization must
be used and averaged when applicable (eg time variation of the
phase or amplitude). EACH will plot H and V polarization separately
but at the same time (e.g. useful to SOLVE DELAY).

SET POLARIZATION NO makes CLIC forget anything about polarization.
This is the mode to use to reduce data from the old receivers (<2007).

.ti -4
2 EXCLUDE
.ti +4
CLIC\SET EXCLUDE proc1 [proc2 [...]]

FIND will exclude observations done under procedure(s) proc1, proc2, ...
from the selection. Known procedures are: CORRELATION, AUTOCORR, GAIN,
DELAY, FOCUS, POINTING, CALIBRATE, IFPB, ONOFF, HOLOGRAPHY, FIVE__POINT,
PSEUDO__CONT, FLUX, STABILITY, CWVR, VLBI, VLBG, OTF, BANDPASS, SKYDIP.

SET EXCLUDE * will clear the exclusion list.

At most 10 procedures are retained; extra arguments are ignored with a
warning. The current exclusion list can be displayed with SHOW CRITERIA
EXCLUDE.

.ti -4
2 PROCEDURE
.ti +4
CLIC\SET PROCEDURE proc

FIND will select observations done under procedure 'proc'. Known
procedures are: CORRELATION, AUTOCORR, GAIN, DELAY, FOCUS, POINTING,
CALIBRATE, IFPB, ONOFF, HOLOGRAPHY, FIVE__POINT, PSEUDO__CONT, FLUX,
STABILITY, CWVR, VLBI, VLBG, OTF, BANDPASS, SKYDIP.

SET PROCEDURE * will disable procedure as a selection criterion.

.ti -4
2 PROJECT
.ti +4
CLIC\SET PROJECT projId

FIND will select observations done for the observing project projId.
SET PROJECT * will disable project number as a selection criterion.

.ti -4
2 QUALITY
.ti +4
CLIC\SET QUALITY Q

FIND will select only observations of quality better than Q (i.e.
less than Q).  When originally written, unless the real time
acquisition system detected a severe problem, all observations have
quality 0, a priori the best. The quality flag of an observation can
be changed using the TAG command. See HELP TAG for the recommended
quality scale.

.ti -4
2 RANGE
.ti +4
CLIC\SET RANGE West East South North

FIND will select all observations with  offsets  in  the  specified
range. Default is * * * *. See also SET OFFSET command.

.ti -4
2 RECEIVER
.ti +4
CLIC\SET RECEIVER number

Use the receiver number as a selection criterion. With the OLD
receiver system at Plateau de Bure (<2007), Receiver 1 is the 3 mm
receiver, while Receiver 2 is the 1.3 mm receiver. With the NEW
receiver system (>2007), 4 receiver bands are available:

.in +2
- receiver band 1: 80-117 GHz (3mm band) -- AVAILABLE

- receiver band 2: 129-174 GHz (2mm band) 

- receiver band 3: 200-257 GHz (1.3mm band) -- AVAILABLE

- receiver band 4: 277-371 GHz (1mm band)
.in -2

The default is SET RECEIVER * : observations with all receivers will
be selected.

For OLD receiver data, SET RECEIVER 1 does automatically a SET PHASE
INTERNAL, while SET RECEIVER 2 does SET PHASE EXTERNAL. See the SET
PHASE command help. For NEW receiver data, SET PHASE INTERNAL is
the default for all bands.

.ti -4
2 RECORD
.ti +4
CLIC\SET RECORD list

Will force all further PLOT commands to use only the records as given
in the list (e.g. r1 r2 r3 to r4 by r5 ...). Very seldom needed.  Use
SET RECORD 1 to 1000000 to reset it.

.ti -4
2 REDUCED
.ti +4
CLIC\SET REDUCED d1 d2

FIND will select all observations with reduction dates  between  d1
and d2 (format jj-mmm-yyyy). Default is * *.

.ti -4
2 REFERENCE
.ti +4
CLIC\SET REFERENCE antenna__number

Enter the logical number of the antenna used as reference for
antenna-based calibrations (both RF passband and phase calibrations).
The phase for this antenna is set to zero. Default is Antenna 1.

.ti -4
2 RF__PASSBAND
.ti +4
CLIC_\SET RF__PASSBAND [ON|OFF] [CHANNEL|FREQUENCY|SPECTRUM] 
.ti +4   
[FILE|MEMORY] [ANTENNA|BASELINE] [DOPPLER|NODOPPLER] 

This command controls the behaviour of CLIC regarding the RF passband
calibration.

.in +4
.ti -4
SET RF__PASSBAND ON|OFF 

Switch ON or OFF the application of RF passband calibration curve in
plotting the data.  The RF passband calibration curve is computed by
SOLVE RF__PASSBAND and stored with the data by STORE RF__PASSBAND.
Subsequent PLOT commands will use or not this curve according to the
status of SET RF__PASSBAND ON|OFF.

.ti -4
SET RF__PASSBAND CHANNEL|FREQUENCY

Use either the channel dependent passband curves or the frequency
dependent passband curve.  The channel-dependent passband curves must
be determined separately for each subband, while the
frequency-dependent passband curve is determined by using SOLVE
RF__PASSBAND on all subbands together (Note: this will not work for
data taken before July 14th 1990). SET RF__PASSBAND FREQUENCY is
recommended.

.ti -4
SET RF__PASSBAND MEMORY|FILE 

Use either the passband curves just determined by SOLVE RF__PASSBAND,
and still present in the program memory, or the passband curves
previously stored in the data headers of the input file by a command
STORE RF__PASSBAND.

.ti -4
SET RF__PASSBAND ANTENNA|BASELINE 

Switch between Antenna-based and Baseline-based RF passband
calibrations. This switch will be active for SOLVE RF__PASSBAND
(passband determination), STORE RF__PASSBAND (passband storing
operation), and SET RF__PASSBAND ON (fpassband application).  Both
baseline-based and antenna-based calibration curves may be stored
alongside in the data header, independently of each other. SET
RF__PASSBAND ANTENNA is recommended.  

.ti -4
SET RF__PASSBAND SPECTRUM

In the MEMORY mode, will look for a SPECTRUM solution in memory (obtained
after a SOLVE RF /SPECTRUM command). In FILE mode, this will look for a scan
stored in the hpb file. In several file are present they can be selected
with SET RF FILE #i. Solutions can be listed with LIST /BANDPASS option.

.ti -4
SET RF__PASSBAND DOPPLER|NODOPPLER

SET RF__PASSBAND DOPPLER enables a shift of the RF SPECTRUM solution
by the difference of LO1 frequency between the solution and the 
observation. SET RF__PASSBAND NODOPPLER deactivates this option. This
applies only to the SET RF__PASSBAND FILE option.

.in -4

.ti -4
2 SKIP
.ti +4
SET SKIP YES|NO

Controls behaviour of FIND command. If set to YES, FIND will skip
autocorrelations that are stored together with cross-correlations, while
keeping the genuine autocorrelations (e.g. AUTO, CAL). 

.ti -4
2 SCAN
.ti +4
CLIC\SET SCAN s1 s2 [s3 s4 ...]

FIND will select all observations with Scan numbers between s1 and s2,
or s3 and s4...  The Scan number, attributed by the on-line
acquisition system may be different from the Observation number which
is used by CLIC to refer to the Observations. Default is * *.

.ti -4
2 SELECTION
.ti +4

CLIC\SET SELECTION mode band subband-list [FREQUENCY freqout]
.ti +4
[/WINDOW fmin fmax [fmin2 fmax2 ...]]

Choose the type of data selection to be done by command TABLE
(to create an output UV table).

.in +4
.ti -2
- The first argument 'mode' is CONTINUUM or LINE, to prepare single
channel or multiple channel maps.

.ti -2
- The second argument is the sideband to be used: UPPER (or USB), LOWER
(or LSB), AVERAGE (or DSB), AUTO or SSB. DSB may be used in conjunction with
CONTINUUM: in this case, two separate visibility points are written,
one for each sideband. DSB used in conjunction with LINE means that
the side band will be selected to match the desired frequency range
(as given in the command TABLE), thus allowing to mix in the same
table data from USB and LSB, if different frequency setups have been
used in different configurations. AUTO will determine for each narrow
input whether the receiver tuning is DSB or SSB and accordingly select DSB 
(write a visibility for each sideband) or the signal sideband if SSB. 
SSB will write one visibility for the signal side band (automatically 
determined). 
This last two options are useful for continuum only. For LINE, they will
just select the matching side band as does DSB.

.ti -2
- The third argument is a subband list.In CONTINUUM mode, subbands
are averaged, in spectral mode they are combined to produce a single
spectrum.  The subband list is given with the same syntax as in the
SET SUBBAND command, e.g. "n1 to n3" or "n1 to n3 and n5".
.in -4

Example:
SET SELECTION CONTINUUM USB C01 AND C03 AND C05 selects continuum
data, USB, and the subbands C01, C03, and C05. 

Arguments "FREQUENCY freqout" are used only for CONTINUUM tables.
They define the frequency (in MHz) used for mapping purposes. U and V
(for each side band in DSB mode) will be scaled to this frequency.
This is intended to combine maps obtained in continuum at slightly
different frequencies.  The default for freqout is the actual
observing frequency , or the frequency used for previous data if data
is appended to a previously existing table by the TABLE command.

Option /WINDOW is used to avoid spectral lines when producing a
continuum table from spectral correlator data. The first two rest
frequencies (in MHz) give the first frequency window in which data is
to be used, the next two give the second frequency window, etc....

.ti -4
2 SOURCE
.ti +4
CLIC\SET SOURCE name1 name2 ...  namen

FIND will select all scans according to the specified source names
(matching is not case-sensitive). Up to 10 source names can be
given. Syntax like NAM* can be used to find all observations with
source name beginning by NAM. Default is *.

.ti -4
2 SORT
.ti +4
CLIC\SET SORT RECEIVER|SCAN|NUM

The output of LIST and LIST /SHORT may be sorted primarily be receiver 
number or scan number or observation number. Use SET SORT to switch 
between the three modes.
Default is RECEIVER mode.

.ti -4
2 NOCHECK
.ti +4
CLIC\SET NOCHECK item1 [item2 [...]]

Disable some consistency checks performed by commands TABLE and SG__TABLE when
appending new scans to an existing UV table. Items may be:

.nf
  SOURCE POINTING PHASE EPOCH SCAN
.fi

This is equivalent to specifying TABLE /NOCHECK (or SG__TABLE /NOCHECK) with
the same items for all subsequent table writes.

This setting is potentially dangerous (it can create tables with inconsistent
metadata). Use SET /DEFAULT to restore the default behaviour (all checks on).

.ti -4
2 SPECTRUM
.ti +4
CLIC\SET SPECTRUM ON|OFF

*** THIS COMMAND IS OBSOLETE ***

.ti -4
2 STEP
.ti +4
CLIC\SET STEP t__step

Select the time interval parameter to be used by  the  SOLVE  PHASE
and  SOLVE  AMPLITUDE  command (time interval between knots of the cubic
spline functions).  Value is in hours (default 3 hours).

.ti -4
2 STOKES
.ti +4
CLIC\SET STOKES HH|VV|HV|VH|NONE CORRECTED|LEAKAGE|NATIVE

Select the Stokes parameter to be displayed.

SET STOKES LEAKAGE allows to correct for source's polarisation to derive
leakages. SET STOKES CORRECTED corrects for instrumental polarisation.
SET STOKES NATIVE undoes any of the preceding

.ti -4
2 SUBBANDS
.ti +4
CLIC\SET SUBBANDS n1 n2 ...  [/WINDOW f1 l1 f2 l2 ...]
.ti +4
CLIC\SET SUBBANDS LINE|CONT
.ti +4
CLIC\SET SUBBANDS ALL
.ti +4
CLIC\SET SUBBANDS EACH
.ti +4
CLIC\SET SUBBANDS HOR|VER 
.ti +4
CLIC\SET SUBBANDS Q1|Q2|Q3|Q4
.ti +4
CLIC\SET SUBBANDS NBC1|NBC2

*** THIS COMMAND IS OBSOLETE ***

Selects the subbands for which data will be displayed by command
PLOT. Valid codes are continuum subbands numbers (C01, C02, ...  C08)
or line subbands numbers (L01, L02, ... L08). These are logical
numbers, so one should select e.g. L01 to L04 if four correlator units
were used, independentely from the physical units actually used. This
is a classical trap, especially with the old receiver system (<2007):
if e.g. units 1 to 5 were used on Receiver 1 and units 6 to 8 on
Receiver 2, the corresponding subbands will be L01 to L05 for the
Receiver 1 scan, and L01 to L03 for the Receiver 2 scan.

Subbands may be grouped by typing e.g. "SET SUBBANDS n1 to n2 and n3
n4". Here, two quantities will be plotted. The first one is either the
average of subbands n1 to n2 and n3 (in time mode), or the
concatenation of spectral data from subbands n1 to n2 and n3 (in
spectral mode). The second quantity plotted is subband n4.

SET SUBBANDS LINE|CONT will switch all subbands to their
line/continuum counterpart, e.g. L01 to L04 will be changed to C01 to
C04 by SET SUBBBANDS CONT. Done by SET X I__F

A number of usefule shortenings are available:

.in +4
.ti -2
- SET SUBBANDS ALL will automatically select all the subbands in
the first scan of the current index, for each command accessing the
data. The subbands are concatenated (equivalent to e.g. 
SET SUBBANDS L01 to L06).  

.ti -2
- SET SUBBANDS EACH will automatically select all the subbands in
the first scan of the current index, for each command accessing the
data. The subband are NOT concatenated (equivalent to e.g. 
SET SUBBANDS L01 L02 L03 L04 L05 L06).

.ti -2 
- SET SUBBANDS HOR|VER will automatically select (in the first scan of
the current index) the subbands connected to the horizontal or
vertical polarization channel (if any). The subbands are concatenated.

.ti -2
- SET SUBBANDS Q1|Q2|Q3|Q4 will automatically select (in the first 
scan of the current index) the subbands connected to the selected
quarter (if any). The subbands are concatenated.

.ti -2
- SET SUBBANDS NBC1|NBC2 will automatically select (in the first 
scan of the current index) the subbands connected to the selected
narrow-band correlator input (if any). The subbands are concatenated.


CLIC\SET SUBBANDS n1 n2 ...  /WINDOW first1 last1 first2 last2 ...

The /WINDOW option select the first and last channels to be used for  
the LINE subbands. There should be one couple of parameter for each
group of subbands.

In spectral mode, the window limits may be used to restrict the plot
to a certain range, e.g.
.ti +4
SET SUBBANDS L01 TO L02 /WINDOW 10 64
.ti +4

will avoid plotting channels 1 to 9 of each of the two subbands L01
and L02 (which are here combined to a single spectrum). This may be
useful to flag meaningless channels at the low-frequency and at the
high frequency ends of each spectral correlator. Note: this is now
done automatically, see SET DROP command.

In time mode, the window limits select the data to be integrated to
compute a single point.For example
.ti +4
SET SUBBANDS L01 L02 /WINDOW 1 10 1 10
will plot data integrated from the first ten channels of the first
line subband, as a first quantity, and data integrated from the first
10 channels of the second line subband, as a second quantity.

Note:  if you want to use both continuum and line subbands, in the  same
plot  page, you should include dummy arguments in the /WINDOW option for
the continuum spectra:
.ti +4
SET SUBBANDS C01 to C10 L01 to L02 /WINDOW 0 0 2 64
(two arguments are needed for each resulting spectrum).
.in -4
.ti +4
This command is now obsolete. Use SET SPW instead.


.ti -4
2 SPW
.ti +4
CLIC\SET SPW 
CLIC\SET SPW n1 n2 ...  [/WINDOW f1 l1 f2 l2 ...] [/NOSELECT]
.ti +4
CLIC\SET SPW LINE|CONT
.ti +4
CLIC\SET SPW ALL
.ti +4
Selects the spectral windows for which data will be displayed by command
PLOT. Valid codes are continuum spw numbers (C001, C002, ...  C008)
or line spw numbers (L001, L002, ... L008). These are logical
numbers, so one should select e.g. L01 to L04 if four correlator units
were used, independentely from the physical units actually used. This
is a classical trap, especially with the old receiver system (<2007):
if e.g. units 1 to 5 were used on Receiver 1 and units 6 to 8 on
Receiver 2, the corresponding spw will be L01 to L05 for the
Receiver 1 scan, and L01 to L03 for the Receiver 2 scan.

Spectral windows may be grouped by typing e.g. "SET SPW n1 to n2 and n3
n4". Here, two quantities will be plotted. The first one is either the
average of spw n1 to n2 and n3 (in time mode), or the
concatenation of spectral data from spw n1 to n2 and n3 (in
spectral mode). The second quantity plotted is spw n4.

SET SPW LINE|CONT will switch all spw to their
line/continuum counterpart, e.g. L01 to L04 will be changed to C01 to
C04 by SET SPW CONT. Done by SET X I__F

SET SPW n1 /NOSELECT will select spectral window n1 while keeping previous
selection mode (i.e. BB or IF selection) which allows to select a 
high-spectral resolution spectral window for delay determination (that 
needs BB or IF selection). This will update the baseband or IF value if 
necessary.

A number of useful shortenings are available:

.in +4
.ti -2
- SET SPW ALL will automatically select all the subbands in
the first scan of the current index, for each command accessing the
data. The subbands are concatenated (equivalent to e.g.
SET SPW L01 to L06).
.in -4


.ti -4
2 TELESCOPE
.ti +4
CLIC\SET TELESCOPE name

FIND will select all scans according to the specified telescope
(i.e. interferometer configuration) name.  Default is *.  Syntax like
NAM* can be used to find all observations with telescope name
beginning by NAM.

.ti -4
2 TIME__ORIGIN
.ti +4
CLIC\SET TIME__ORIGIN  *|date 

Specify the time origin for the abscissa in time plots. This is
normally the day for which the first data is plotted, and time is
displayed in hours since that day. This day is reset by using PLOT
/RESET.

"SET TIME__ORIGIN date" forces the time origin to the specified day
(e.g. 01-AUG-2004). "SET TIME__ORIGIN *" resets the default
(automatic) behaviour.

.ti -4
2 TOTAL__POWER
.ti +4
CLIC\SET TOTAL__POWER RAW|PHYSICAL

For new receivers, switch between total power as measured by the
correlator (raw) in units of (sigma/v)^2 and "physical" temperature
scale (in K). 

.ti -4
2 TREC
.ti +4
CLIC\SET TREC value /ANTENNA i|ALL

Give the value of the receiver temperature, to be used by the command
ATMOSPHERE. Use * instead of the value to force the use of the numbers
stored in the file.

.ti -4 
2 TRIANGLE 
.ti +4 
CLIC\SET TRIANGLE t1 t2 ... PHYSICAL|LOGICAL

Selects the triangle products for which data will be  displayed  by
command  PLOT.  Valid  triangles are codes as e.g. "123" or "345".
This command is exclusive with commands  SET  BASELINES  and
SET  ANTENNAS.   

This command will be effective only if the triangle products have been
computed and stored in the data by commands SPECTRUM/TRIANGLE or
COMPRESS/TRIANGLE.  In that case the triangle products will have been
averaged by these commands; since the phase of the triangle products
are closure quantities, the amplitude of the average should not be
affected by atmospheric decorrelation.

.ti -4
2 TYPE
.ti +4
CLIC\SET TYPE par

FIND will select observations of specified type 'par'.  This may be
OBJECT, PHASE (i.e. calibrators), or RF (i.e. RF passband calibrator;
this is obsolete). Use argument "*" to disable selection by source
type.

.ti -4
2 UV__RANGE
.ti +4
CLIC\SET UV__RANGE UVmin UVmax

This command will force all further PLOT commands to use only the 
points that are within this range in the UV plane, i.e. those 
for which UVmin < sqrt(U**2+V**2) < UVmax. 



.ti -4
2 VIRTUAL
.ti +4
CLIC\SET VIRTUAL

*** THIS COMMAND IS OBSOLETE ***

.ti -4
2 WATER
.ti +4
CLIC\SET WATER value 

Give the value of the water vapor content (in mm), to be used by the
command ATMOSPHERE. Use * instead of the value to force the use of the
numbers stored in the file.

.ti -4
2 WEIGHTS
.ti +4
CLIC\SET WEIGHTS [TSYS ON|OFF] [CALIBRATION ON|OFF]
.ti +4
[BASELINE ON exponent|OFF]

Selects the way data weights are computed. These weights are used in
particular by the command TABLE.

Weights are always proportional to observing time.

With TSYS ON, data is also weighted by 1/TSYS**2, where TSYS is the
equivalent system temperature (the geometrical mean of the system
temperatures of both antennas, for a given baseline). With TSYS OFF,
this factor is not applied.

With CALIBRATION ON, data is also weighted by 1/CAL**2, where CAL is
the amplitude instrumental calibration factor (if any). If no
amplitude instrumental calibration function is applied (absolute
amplitude), this weighting should have no effect. With CALIBRATION
OFF, weights are not affected by amplitude calibration.

With BASELINE ON exponent, data weights are additionally scaled by the
projected baseline length in the UV plane according to
(sqrt(U**2+V**2)/15.)**exponent. This can be used to give more or less
weight to long projected baselines in subsequent fits. The exponent
argument is mandatory when switching this mode on. With BASELINE OFF,
this extra scaling is disabled. This option is not used by the TABLE
command.

Default is TSYS ON, CALIBRATION ON and BASELINE OFF.

Use SHOW WEIGHTS to display the current settings.

.ti -4
2 X
.ti +4
CLIC\SET X param1 [param2 ...] [/LIMITS min1 max1 [min2 max2 ...]]

Choose the parameters to be plotted along X-axes by command PLOT.

.so clic-help-setx.nroff 

The available parameters are the same as with the SET Y command.
Default is SET X TIME.


The /LIMITS option is used to specify fixed limits, e.g.: "SET X TIME
/LIMITS t1 t2" where t1 and t2 are the time limits to be used in this
example.  The codes "*" and "=" may be used. "*" means that the limits
are automatically adjusted to the data, separately in each box; "="
means that common limits to all boxes are computed.

For time-like plots, the defaults are "/LIMITS * * ".  For
frequency-like plots, the defaults are "/LIMITS = =".

.ti -4
2 Y
.ti +4
CLIC\SET Y param1 [param2 ...] [/LIMITS min1 max1 [min2 max2 ...]]

Choose the parameter to be plotted along Y-axes by command PLOT.

.so clic-help-setx.nroff

The available parameters are the same as with the SET Y command.
Default is SET Y AMPLITUDE PHASE.

The /LIMITS option is used to specify fixed limits, e.g.: "SET Y AMPLITUDE
/LIMITS a1 a2" where a1 and a2 are the amplitude limits to be used in this
example.  The codes "*" and "=" may be used. "*" means that the limits
are automatically adjusted to the data, separately in each box; "="
means that common limits to all boxes are computed.

Default limits are provided for AMPLITUDE and PHASE only: 0 * * * if
SET PHASE CONTINUOUS is effective, 0 * -180 180 if SET PHASE JUMPY
DEGREE (with corresponding values if SET PHASE RADIANS).

.ti -4
1 SHOW
.ti +4
CLIC\SHOW Argument

Display the parameters defined by SET. Each "SET Argument" command 
has an equivalent "SHOW Argument".

In addtion, "SHOW ALL" will display all parameters specified by SET.
"SHOW CRITERIA" will display only selection criteria for the command
FIND, "SHOW DISPLAY" will give only the parameters relevant to command
PLOT, and "SHOW GENERAL" will give the rest of the parameters.

.ti -4
1 SOLVE
.ti +4
CLIC\SOLVE Item

This is a  command  to  determine  interferometer  parameters  from
measured data. SOLVE is processing the current index.

.ti -4
2 AMPLITUDE
.ti +4
CLIC\SOLVE AMPLITUDE  [/PLOT] [/BREAK kind time [kind time ...]  
.ti +4
[/POLYNOMIAL [degree]] [/WEIGHT] [/RESET]

This command fits a mathematical function into the measured amplitude
of the sources in the current index (presumably calibrators).  This
data must have been selected and plotted in axes : SET X TIME and SET
Y AMPLITUDE for the baselines and bands of interest, specified by the
corresponding SET commands. The calibration function is kept in
memory.  Command STORE AMPLITUDE should be used next to store this
function in the header of source observations, after a change in the
index to select the appropriate scans. 

SOLVE AMPLITUDE internally and temporarily resets SET AMPLITUDE
to SCALED.

In antenna mode (selected by SET AMPLITUDE ANTENNA), the averaged
phase and amplitude closures are computed, as well as their standard
deviations. The phase closures should be close to zero, while the
amplitude closures should be close to 100%. Strong deviations of
amplitude closures from 100% are an indication of amplitude loss on
long baselines, due to phase decorrelation during the time
averaging. The fit then shows strong systematic errors; if this
occurs, baseline based calibration of the amplitudes might be
preferred.

Option /PLOT will plot the fitted curve over the data. Option /RESET 
will reset the calibration curve in memory.

Fitted curves may be of two kinds:

.in +4
.ti -2
- Cubic splines (the default).  By default knots are regularly spaced
with an interval between knots set by the SET STEP command.
Additional knots may be introduced with the option "/BREAK kind time
[kind time ...]"  which introduces a break at abscissa 'time'; 'kind'
is an integer in the range 0-3; 0 means that a discontinuity will be
present, 1 that the first derivative will be discontinuous, and so on.
Several breaks may be introduced. The program will detect an error if
too many breaks are introduced, compared to the density of data
points.

.ti -2
- Polynomial curves may be used instead.  For this the option is:
/POLYNOMIAL [degree] indicating the degree of the polynomial (default
0).
.in -4

Normally the data points are all assigned the same weight for the fit.
With option /WEIGHT, the data points are weighted according to their
errors. 

.ti -4
2 BASELINE
.ti +4
CLIC\SOLVE BASELINE [/OFFSET b1 dx1 dy1 dz1 b2  ...]  
.ti +4
[/SEARCH range interval] [/POLYNOMIAL degree] [/RESET] [/PLOT] [/SIN]

This uses a linear method to determine baselines. The baselines to be
determined must have been selected by the SET BASELINE command, and
the data plotted; plot axes must have been previously selected by :
SET X HOUR__ANGLE DECLINATION and SET Y PHASE. With SET ANTENNA in
action the antenna position offsets are directly fitted to the antenna
phases, ensuring baseline closure.

The fitting should work only if the starting values are within half a
wavelength in any direction of the true values. Use option /OFFSET to
correct the phases for an offset (dx1,dy1,dz1) in baseline b1 before
fitting.  This is needed if the baseline was wrong by more than half a
wavelength. Offsets are to be given in meters.

The results are given as offsets in  meters  to  be  added  to  the
baseline  used  for  data  acquisition (which may be read by SIC\EXAMINE
BASELINE).  The total fitted baseline is also given in meters,  as  well
as  the  rms  of  the residuals in phase units.  Two sets of offsets are
given:  the first set (dx, dy, dz) are the offsets with respect  to  the
antenna  positions actually used, while the secoond set (DX, DY, DZ) are
with respect to the standard antenna coordinates (the default values  in
OBS).

The /SEARCH option  enables  an  automatic  search  with  starting
offsets  scanning a 3-d box in dx, dy, dz, by steps of half a wavelength
in the three directions.  The arguments range and interval are in meters  
(scanning  is from  -range/2 to +range/2, default -0.005 to 0.005).  Only 
the solution with the minimum rms is kept.  

With option /POLYNOMIAL degree, and  if  SET  X  TIME  is  used  in
addition of HOUR__ANGLE and DECLINATION, a polynomial function of time is
included in the phase function being fitted.  The degree may range  from
0 (the default) to 3.  In that case command RESIDUALS will also plot the
residuals as a function of time.

The /RESET option resets the solutions in memory.

The /PLOT option allows to plot the data used for fitting.

Use command RESIDUALS BASELINE to display the fit residuals (phase
should be constant). Use later command PRINT BASELINE to create a
procedure file (named CLIC-BASELINE.OBS) containing the antenna
position offsets.  This procedure file may be executed by the
observing program OBS on the control computer bure01.

If one specify elevation as an additional X variable (e.g. SET X
HOUR__ANGLE DECLINATION TIME ELEVATION), then an additional parameter
is fitted: the offsets between elevation and azimuth axes (or rather
the differences between antennas). These differing offsets result in a
phase effect proportional to the cosine of elevation. In antenna mode,
these offsets are given for each antenna in meters. In baseline mode,
only differences are computed. To further correct for this effect use
the command MODIFY AXES. One can optionnaly fit a sinus instead of 
a cosinus in this specific case using option /SIN.


.ti -4
2 DELAY
.ti +4
CLIC\SOLVE DELAY [/SEARCH range interval] [/PLOT] [/PRINT]

This uses a linear method to determine delays.  The baselines to be
determined must have been selected by the SET BASELINE (or SET
ANTENNA) command, and the data plotted; plot axes must have been
previously selected by :SET X I__FREQUENCY and SET Y PHASE.

The /SEARCH  option  enables  an  automatic  search  with  starting
offsets  from -range/2 to +range/2 by steps of given interval.
The default range is 200 nanoseconds, with interval of 1 nanosecond.

With SET ANTENNA in action the antenna delays are directly fitted to
the antenna phases, ensuring delay closure.

The results are given in nanoseconds. Use option /PRINT or command
PRINT DELAY to create a procedure file (INTER__OBS:clic-delay.obs)
containing the fitted antenna delays.  This procedure file may be
executed by the observing program OBS on the control computer bure01.

With option /PLOT, the fitted phases will be plotted over the data.
One needs to select an IF or a baseband beforehand (set SET IF or SET
BB).

.ti -4
2 FLUX
.ti +4
CLIC\SOLVE FLUX [NOREFERENCE] [BEST n] [REAL] [/RESET] [/OUTPUT file]

Calculate the fluxes of the sources in the current index or the
antenna efficiencies (Jansky to Kelvin) if the source flux is known.
The command can also be used to bootstrap source fluxes from a known
source.

It should be used before computing any amplitude calibration, on an
index covering a reasonably short time interval to avoid possible
efficiency variations.

The commands should be used in the following way:

.in +4 
.ti -2 
- The command SET FLUX is used to define the flux of one, or several
of the sources in the current index for which the flux is
known. Frequencies and dates may be specified.

.ti -2
- Then the command SOLVE FLUX will use the sources of known flux
(optionally with matching frequencies and dates) to determine the
efficiencies for all antennas. SOLVE FLUX now gives the decorrelation
factor relative to the efficiencies logged in the scan headers
(assumed to be the standard single-dish efficiencies).

.ti -2 
- SOLVE FLUX then uses these antenna efficiences to compute the
fluxes of all other sources. IF the keyword "BEST n" is present, the n
antennas giving the highest fluxes will be used for averaging (n is 1
to the number of available antennas). Default is n=3.

.ti -2
- The command SHOW FLUX will give the current flux list. The reference
sources are listed with a "FIXED" keyword, while the fluxes determined
by SOLVE FLUX are listed as "FREE".

.ti -2
- SOLVE FLUX /RESET can be used to reset the flux list (i.e. remove
from the list all sources whose flux is not fixed) before processing.

.ti -2
- SOLVE FLUX /OUTPUT file [NEW] will produce an output file with the
results printed for each antenna. Use keyword NEW to open a new file.

.ti -2
- The command PRINT FLUX will create a procedure that may be used later
to reload these fluxes in CLIC, if needed.

.ti -2
- The command STORE FLUX will store the fluxes and efficiencies in
the headers of the observations in the current index.
.in -4

If no reference sources are available, the keyword NOREFERENCE should
be given, and the default efficiencies stored in the data header will
be used (step 2 in the above list is bypassed).

The keyword REAL forces SOLVE FLUX to use the real part of the
visibilities instead of the amplitude to derive the antenna
efficiencies and source fluxes. This is only for test purposes and
must not be used without asking an expert.

.ti -4
2 SPIDX
.ti +4
CLIC\SOLVE SPIDX [NOREFERENCE] [BEST n] [REAL] [/RESET] [/OUTPUT file]

Calculate the spectral indexes of the sources in the current index or
the antenna efficiencies (Jansky to Kelvin) if the source spectral
index is known.  The command can also be used to bootstrap source
spectral indexes from a known source.

It should be used before computing any amplitude calibration, on an
index covering a reasonably short time interval to avoid possible
efficiency variations.

The commands should be used in the following way:

.in +4 .ti -2 
- The command SET SPIDX is used to define the spectral
index of one, or several of the sources in the current index for which
the spectral index is known. Frequencies and dates may be specified.

.ti -2 
- Then the command SOLVE SPIDX will use the sources of known
spectral index (optionally with matching frequencies and dates) to
determine the efficiencies for all antennas. SOLVE SPIDX now gives the
decorrelation factor relative to the efficiencies logged in the scan
headers (assumed to be the standard single-dish efficiencies).

.ti -2 
- SOLVE SPIDX then uses these antenna efficiences to compute
the spectral indexes of all other sources. IF the keyword "BEST n" is
present, the n antennas giving the highest fluxes will be used for
averaging (n is 1 to the number of available antennas). Default is
n=3.

.ti -2 
- The command SHOW SPIDX will give the current spectral index
list. The reference sources are listed with a "FIXED" keyword, while
the spectral indexes determined by SOLVE SPIDX are listed as "FREE".

.ti -2 
- SOLVE SPIDX /RESET can be used to reset the spectral index
list (i.e. remove from the list all sources whose spectral index is
not fixed) before processing.

.ti -2
- SOLVE SPIDX /OUTPUT file [NEW] will produce an output file with the
results printed for each antenna. Use keyword NEW to open a new file.

.ti -2
- The command STORE SPIDX will store the spectral indexes and efficiencies in
the headers of the observations in the current index.
.in -4

If no reference sources are available, the keyword NOREFERENCE should
be given, and the default efficiencies stored in the data header will
be used (step 2 in the above list is bypassed).

The keyword REAL forces SOLVE SPIDX to use the real part of the
visibilities instead of the amplitude to derive the antenna
efficiencies and source spectral indexes. This is only for test
purposes and must not be used without asking an expert.

.ti -4
2 FIVE
.ti +4
CLIC\SOLVE FIVE [beam] [/PLOT] [/PRINT]
.ti +4
[/OUTPUT filename [NEW|APPEND] [FLUX] [TPOINT]] 

Find pointing corrections from FIVE point scans.  All five-point scans
in the current index are processed by a gaussian fit. Its width can
be fixed if the argument 'beam' is given (in arcsec). All continuum
subbands and both side bands are averaged. The fits may be displayed
with option /PLOT.

The presence of option /PRINT produces a procedure file
(INTER__OBS:pointing.obs), to be used in OBS for introducing the
fitted pointing offset.

The results may also be written on an output ASCII file if /OUTPUT is
given.  The file is given extension .lis by default; a new file is
opened except if APPEND is given as a second argument of option
/OUTPUT. The file is by default in a format suitable for the
determination of a pointing model (program POINT at BURE). The
presence of optional argument FLUX changes the output format for the
determination of relative fluxes (by ASTRO). With argument TPOINT, the
output is written in a format suitable for processing by the TPOINT
program.

.ti -4
2 FOCUS
.ti +4
CLIC\SOLVE FOCUS [/PLOT] [/COMPRESS time__max] [/PRINT]
.ti +4
[/OUTPUT filename [NEW][OLD]] [/TOTAL] [/FIX par1 [value] ...]

Find focus corrections from a FOCUS scan using a parabolic fit.  All
focus scans in the current index are processed. SET AVERAGE METHOD SCALAR
is recommended.  The fits may be displayed with option /PLOT.

The option /COMPRESS may be used to average data in a given time
interval before processing, to improve the signal-to-noise ratio.
Default is 5 seconds.

The presence of option /PRINT produces a procedure file
(INTER__OBS:focus.obs), to be used in OBS for introducing the fitted
focus offset. With option /OUTPUT, results of the fit, together with
elevation and azimuth, are written in an output ASCII file, for
further examination.

With option /TOTAL, SOLVE FOCUS uses the total power to solve for
axial focus errors. In that case, option /FIX may be used to fix one
parameter. Possible parameters are:

.ti +4
FOCUS: the axial focus error (mm)
.ti +4
PEAK: the peak amplitude, in total power units
.ti +4
WIDTH: the HPW of focus curve  (mm)
.ti +4
ZERO: the off-source zero level, in total power units

With /TOTAL, /COMPRESS does the ON-OFF combination if in beam
switching mode. In that case ZERO is preferrably fixed to zero
(e.g. SOLVE FOCUS /TOTAL /COMPRESS /PLOT /FIX ZERO 0).

.ti -4 
2 GAIN
.ti +4
CLIC\SOLVE GAIN [SCAN] [/PRINT] [/OFFSET]

Compute the receiver gain ratio (Image Side Band over Signal Side
Band) from correlation data on a continuum source. Compute also the
LO1 and LO3 phases that should be used in real time to have zero
phases in both side bands (DSB receiver up to 2006), or the relative
phases between basebands (SSB dual-polarisation receivers).

The data from all the scans in the current index are averaged except
if optional argument SCAN is given, in which case the gain ratios are
computed for each scan.

Option /PRINT produces a procedure INTER__OBS:gain.obs to set the
gains (and phases) in OBS.

Option /OFFSET allow to only compute the phases, not the gain ratio.

.ti -4
2 HOLOGRAPHY
.ti +4
CLIC\SOLVE HOLOGRAPHY [NPOINTS npix] 
.ti +4
[FREE [RINGS r1 r2] [SECTOR s1 s2]] 
.ti +4
[MODES nmodes] 
.ti +4
[ITER niter gain] 
.ti +4
[MASK npanels p1 p2 p3 ...] 
.ti +4
[BASELINES b1 b2 b3 ... ] 
.ti +4
[POINTING x1 y1] 
.ti +4
[REFERENCE a1]
.ti +4
[DISTANCE dist] 
.ti +4
[DIAMETER diam] 
.ti +4
[DEFOCUS df] 
.ti +4
[TAPER t]
.ti +4
[FOCUS df] 
.ti +4
[TYPE ASDM|VERTEX|AEC|MELCO12__1|MELCO12__2|MELCO12__3|BURE|IRAM30]
.ti +4
[TEST testFile] 
.ti +4
[FRESNEL] 
.ti +4
[NOFOCUS]
.ti +4
[NOXYFOCUS]
.ti +4
[ASTIGMATISM [ANGLE astangle]]
.ti +4
[APODIZE] 
.ti +4
[NOFEED] 
.ti +4
[BEAM SIGNAL|REFERENCE] 
.ti +4
[RIGGING e1 e2] 
.ti +4
[TEMP__BIAS t]
.ti +4
[FIXSPACING s]
.ti +4
[/PLOT [AMP amin amax astep] [PHA pmin pmax pstep] 
.ti +4
[ERRORS emin emax estep]  [NUMBER]] 
.ti +4
[/OFFSET x y z]
.ti +4
[/THRESHOLD microns [nsigma]]


This command computes an antenna surface map from a set of holography
measurements. The set of scans (procedure HOLO) should have first been
calibrated in phase, amplitude and RF passband relative to interspaced
correlation scans in the direction of the source.  The map will be
computed from the first band and subband sets chosen with commands SET
BAND and SET SUBBAND. SET BAND AVERAGE is recommended for continuum
measurements; only continuum subbands should be used. For line
measurements, the continuum width of one of the correlator units
should match the actual line width for better sensitivity.  The
antenna to be studied should be selected by command SET ANTENNA i.
Data from the baselines linking this antenna (scanned) to other
(fixed) available antennas are averaged.


SOLVING FOR ANTENNA PARAMETERS

The amplitude and phase maps are obtained by FFT of the observed beam
map. The maps will be square (npix by npix pixels). The default for
npix is 64, it should be greater than the number of observed
holography scans (usually 16 or 32).

After FFT a gaussian illumination function is fitted in the
amplitudes, giving the offset from the center (in meters) and the edge
taper (in dB).  If /PLOT is given, the amplitude map will be displayed
(in decibels), from -15 to 0 dB, with contours in steps of 3db (these
may be changed using "/PLOT AMP amin, amax and astep").

A least square fit is used to correct the phases from a remaining
phase offset, pointing errors, and focus offsets. The panel rings
following the keyword FREE are not used for this fit. If /PLOT is
given, the antenna normal surface errors will be shown, in
micrometers, from -500 to 500 mum, with contours in steps of 100 mum
(these may be changed using "/PLOT ERRORS emin, emax and estep"). If
/PLOT PHASE is given, the residual phase map will be plotted instead
of surface errors, in radians from -pi to pi, with contours in steps
of 0.2 radian. If this map shows remaining 2*pi discontinuities, or if
focus offsets larger that 1mm are found, you should try using option
/OFFSET to correct the phases for an offset (x,y,z in meters) in the
focus coordinates, before fitting. This should lead to better rms
values.

The rms values for the phase and the normal surface errors (in radians
and micrometers) are given, both with and without amplitude
weighting. The contribution of the illumination amplitude distribution
and of the observed phase errors to the antenna efficiency are given.

A gildas image file of the results is kept
(e.g. "jj-mmm-yyyy-an1.map"), in which plane 3 in the amplitude in dB,
plane 4 the raw phases and plane 2 the residual phase in radians
(plane 1 contains the fitted amplitude, i.e.  a Gaussian).


SOLVING FOR PANEL DISPLACEMENTS

Finally, if "PLOT MODE nmodes" is entered with nmodes larger than 0, a
listing of panels displacements is computed. This uses the parameter
nmodes which is the number of modes used for each panel: 1 is the
translation mode only (normal to the antenna surface); 3 (the usual
setting) adds both tilt modes, radial and tangential, but no panel
deformation; 4 adds a torsion mode and 5 a motion of the panel center
relative to its edges (there are only 5 screws for each panel, thus
only 5 possible modes).

The results of this computation is written in a file "panels-an1.dat"
(or similar name for other antennas). In this file, a line for each
panel is printed. The first two numbers are the panel numbers,
followed by up to five screw settings (three only for the inner
ring). All screw settings are equal if nmodes was set to 1, only one
number is then printed.

The fit is obtained iteratively: the panel orthogonal deformation
modes are computed from the aperture phase, then the phase change that
these deformations would have caused is computed (by doing a FFT to
the beam map, doing a cut-off at the observed map size, followed by a
FFT back to the aperture plane), and subtracted from the aperture
phase; second order panel deformations are computed from these
residuals, and so on. The number of iterations niter and a gain to
this iterative procedure may be specified (ITER niter gain); their
default values are 5 and 1.0 . Use ITER 0 for no iterative procedure
at all. At each step the phase residual rms and the rms of panel
deformations fitted are given (weighted by the fitted amplitude
illumination and counted perpendicularly to the surface).

Variables containing antenna parameters are available:
.in +4
.ti -2 
-TAPER__X, TAPER__Y: illumination tapers.
.ti -2 
-OFFSET__X, OFFSET__Y: illumination offsets.
.br
.ti -2 
-RMS__PHA__U, RMS__PHA__W: phase r.m.s (unweigthed or weighted by illumination).
.br
.ti -2 
-ETA, ETA__230, ETA__345: aperture efficiency at observing frequency, 230 and 
345 GHz.
.br
.ti -2 
-ETA__I, ETA__S: illumination and feed taper efficiency. 
.ti -2 
.br
-RUZE, RUZE__230, RUZE__345: ruze factor at observing frequency, 230 and 345 GHZ
.br
.ti -2 
-JYKEL, JYKEL__230, JYKEL__345: antenna efficiency at observing frequency, 230 and 345 GHz.
.ti -2 
-HOLO__FOCUS: focus position.
.ti -2 
-HOLO__RMS: surface r.m.s. (unweighted or weighted by illumination).
.ti -2 
-HOLO__RING: rings r.m.s
.in -4

SOLVE HOLOGRAPHY options

SOLVE HOLOGRAPHY NPOINTS npix

.in +4
Gives the number of pixels of the amplitude and phase maps. Default is 64. 
.in -4 

SOLVE HOLOGRAPHY MODE nmodes

.in +4
Force CLIC to compute the panel displacements (see above). 
nmodes is 1 to 5.
.in -4

SOLVE HOLOGRAPHY ITER niter gain

.in +4
Select the number of iteration and gain to be used for the panel
displacement determination (see above). Does make sense only if 
used in conjonction with the MODES keyword.
.in -4

SOLVE HOLOGRAPHY BASELINES b1 b2 b3 ... 

.in +4
By default, all baselines connecting the antenna to be studied
(selected by SET ANTENNA) to a fixed antenna are used. The
keyword BASELINES allows to specifically select the baselines
to be used.
.in -4

SOLVE HOLOGRAPHY MASK npanels p1 p2 p3 ...

.in +4
Allows to mask some panels.
.in -4

SOLVE HOLOGRAPHY REFERENCE a1

.in +4
Allow to select a reference baseline (ALMA specific)
.in -4

SOLVE HOLOGRAPHY FREE [RINGS r1 r2] [SECTOR s1 s2]

.in +4
With keyword RINGS, indicates the ring NOT to be used for paraboloid fit.
With keyword SECTORS, indicates the sectors NOT to be used for paraboloid fit.
.in -4

SOLVE HOLOGRAPHY ASTIGMATISM [ANGLE astAngle] 

.in +4
Options for fitting. With keyword ANGLE, SOLVE HOLOGRAPHY ASTIGMATISM
uses a forced astAngle (in degrees) for astigmatism orientation and fits
only astigmatism r.m.s.
.in -4

SOLVE HOLOGRAPHY NOFOCUS NOXYFOCUS

.in +4
Options for fitting. With keyword NOFOCUS, no attempt is made to fit
the focus. With keyword NOXYFOCUS, only the z component of focus is fitted.
.in -4

SOLVE HOLOGRAPHY FOCUS f

.in +4
Allows to speficy value of focus (in m).
.in -4

SOLVE HOLOGRAPHY POINTING p1 p2 

.in +4
Allow to add pointing corrections in case the coordinates stored in the data
file are wrong.
.in -4

SOLVE HOLOGRAPHY DEFOCUS df

.in +4
Allow to introduce known defocus (useful for near-field measurements).
.in -4

SOLVE HOLOGRAPHY TAPER t

.in +4
Allow to set the value of the illumination taper at the edge of the primary 
(power).
.in -4

SOLVE HOLOGRAPHY DIAMETER d

.in +4
Sets antenna diameter to d.
.in -4

SOLVE HOLOGRAPHY TEST testFile

.in +4
Use a test beam file instead of real data from the CLIC
data file (must be a gdf .beam file).
.in -4

SOLVE HOLOGRAPHY DISTANCE dist

.in +4
Gives distance of the source, in meters. Not relevant for
astronomical sources, of course. Any distance larger than
than 1000 km (which is the default) forces the FRESNEL 
approximation. 
.in -4

SOLVE HOLOGRAPHY FRESNEL

.in +4

Use Fresnel approximation (use only the Fourier transform, neglect the
additional terms in the complex exponential argument). This is the
default mode for long distance (e.g. astronomical) sources, but must
be indicated if a DISTANCE has been entered.  
.in -4

SOLVE HOLOGRAPHY TYPE BURE|IRAM30

.in +4
Allow to force an antenna type.
.in -4

SOLVE HOLOGRAPHY APODIZE

.in +4
Do an apodization of the beam map (quadratic, down to zero on map edges).
.in -4

SOLVE HOLOGRAPHY BEAM REFERENCE

.in +4
Allows to do just the gridding of a reference beam (exits before FFT). This is
useful for special holography receivers that have a signal and reference beam.
.in -4

SOLVE HOLOGRAPHY /OFFSET x y z

.in +4
Introduce a focus offset (in m) around which the solution will be searched.
.in -4

SOLVE HOLOGRAPHY /TRESHOLD microns [nsigmas]

.in +4
Use a cutoff threshold in absolute value of displacement and/or number 
of sigmas for listing screws in panel adjustements. If only one value
is given, this is the threshold in microns. For a threshold only in sigmas,
use /THRESHOLD 0.0 nsigmas. Defaut is 0.0, 0.0.
.in -4

SOLVE HOLOGRAPHY RIGGING [e1 e2]

.in +4
Correct for gravitational deformations from the average of the two elevations 
e1 and e2 (default 20 and 90 degrees).
.in -4

SOLVE HOLOGRAPHY TEMP__BIAS t

.in +4
Correct for the thermal deformations between ambiant temperature and bias 
temperature t.
.in -4

SOLVE HOLOGRAPHY FIXSPACING s

.in +4
Set the spacing used for gridding.
.in -4

SOLVE HOLOGRAPHY /PLOT [AMP amin amax astep] [PHA pmin pmax pstep] [ERRORS emin emax estep] [NUMBER]

.in +4 
With /PLOT, SOLVE HOLOGRAPHY will plots the results: two maps
are displayed, which by default are the amplitude illumination pattern
(default plot limits are -15dB to 0dB by step of 3dB) and the antenna
normal surface errors (from -500 to 500 mum, with contours in steps of
100 mum). The min., max., and steps can be changed with "/PLOT AMP amin
amax astep" and "/PLOT ERRORS emin emax estep". With "/PLOT PHASE",
the phase residuals are plotted instead of the surface errors. Default
are from -pi to +pi by step of 0.2 radians.

If NUMBER is given as a /PLOT argument, the panels numbers are drawn.
.in -4

.ti -4
2 PHASE
.ti +4
CLIC\SOLVE PHASE [/PLOT] [/BREAK kind time [kind time ...]]   
.ti +4
[/POLYNOMIAL degree] [/WEIGHT] [/RESET]

This will fit a mathematical function into the measured phases of the
sources in the current index (presumably calibrators).  This data must
have been selected and plotted in axes : SET X TIME and SET Y PHASE
for the baselines and bands of interest, specified by the
corresponding SET commands.  Phases should be continuous (SET PHASE
CONTINUOUS). The calibration function is kept in memory. Command
STORE should be used next to store this function in the header of
source observations, after a change in the index to select the
appropriate scans.

SOLVE PHASE internally and temporarily resets SET PHASE to ABSOLUTE.
The INTERNAL|EXTERNAL mode is kept to allow determining a phase curve
on top of an external receiver reference.

In antenna mode (selected by SET PHASE ANTENNA), the averaged
phase and amplitude closures are computed, as well as their standard
deviations. The phase closures should be close to zero, while the
amplitude closures should be close to 100%. 

Option /PLOT will plot the fitted curve over the data. Option /RESET
will reset the calibration curve in memory.

Fitted curves may be of two kinds:

.in +4
.ti -2
- Cubic splines (the default).  By default knots are regularly spaced
with an interval between knots set by the SET STEP command.
Additional knots may be introduced with the option "/BREAK kind time
[kind time ...]"  which introduces a break at abscissa 'time'; 'kind'
is an integer in the range 0-3; 0 means that a discontinuity will be
present, 1 that the first derivative will be discontinuous, and so on.
Several breaks may be introduced. The program will detect an error if
too many breaks are introduced, compared to the density of data
points.
.ti -2
- Polynomial curves may be used instead.  For this the option is:
/POLYNOMIAL [degree] indicating the degree of the polynomial (default
0).
.in -4

Normally the data points are all assigned the same weight for the fit.
With option /WEIGHT, the data points are weighted according to their
errors. 

.ti -4
2 POINTING
.ti +4
CLIC\SOLVE POINTING [beam] [/PLOT] [/COMPRESS [time__max]] [/PRINT]
.ti +4
[/OUTPUT filename [NEW|APPEND] [FLUX] [TPOINT]] 
.ti +4
[/TOTAL] [/FIX param1 [value1] param2 [value2] ... ]

Find pointing corrections from POINTING scans.  All pointing scans in
the current index are processed by a gaussian fit. Its width can be
fixed if the argument 'beam' is given (in arcsec). All continuum
subbands and both side bands are averaged.  SET AVERAGE METHOD SCALAR
is recommended. The fits may be displayed with option /PLOT.

The option /COMPRESS may be used to average data in a given time
interval before processing, to improve the signal-to-noise ratio.
Default is 4 seconds.

The presence of option /PRINT produces a procedure file
(INTER__OBS:pointing.obs), to be used in OBS for introducing the
fitted pointing offset.

The results may also be written on an output ASCII file if /OUTPUT is
given.  The file is given extension .lis by default; a new file is
opened except if APPEND is given as a second argument of option
/OUTPUT. The file is by default in a format suitable for the
determination of a pointing model (program POINT at BURE). The
presence of optional argument FLUX changes the output format for the
determination of relative fluxes (by ASTRO). With argument TPOINT, the
output is written in a format suitable for processing by the TPOINT
program.

With option /TOTAL, SOLVE POINTING uses the total power to solve for
pointing errors. In that case, option /FIX may be used to fix one
parameter. Possible parameters are:

.ti +4
AZ: the azimuth collimation error (arc sec.)
.ti +4
EL: the elevation collimation error (arc sec.)
.ti +4
PEAK: the peak amplitude, in total power units
.ti +4
WIDTH: the HPBW (arc sec.)
.ti +4
ZERO: the off-source zero level, in total power units

With /TOTAL, /COMPRESS does the ON-OFF combination if in beam
switching mode. In that case ZERO is preferrably fixed to zero
(e.g. SOLVE POINTING /TOTAL /COMPRESS /PLOT /FIX ZERO 0).

.ti -4
2 RF__PASSBAND
.ti +4
CLIC\SOLVE RF__PASSBAND [da] [dp] [/PLOT] [/SPECTRUM] [/RESET] 
.ti +4
CLIC\SOLVE RF__PASSBAND [/IGNORE a1 a2 ...] [/CROSSED]

Solve for passband calibration curves, by fitting it to the amplitudes
and phases. The current index should contain calibration observations
of strong continuum sources (RF passband calibrator). The behaviour of
this command depends on the current mode of RF passband calibration
(Frequency, Channel -- deprecated, or Spectrum). A baseband should have 
been selected beforehand (see SET BBAND).

.in +4
.ti -2
- For frequency-dependent RF passabnd calibration (SET RF__PASSBAND
FREQUENCY, recommended): the resolution is normally done using all the
spectral subbands plotted together, as a function of intermediate
frequency. It should be done separately for each baseband and sideband
(if applicable). A single frequency-dependent polynomial is fitted, a high
degree might be necessary for the phase, if band edges are used (up to
50 is feasible).
 
.ti -2
- For channel dependent RF passband calibration (SET RF__PASSBAND
CHANNEL)

(i) For continuum, the data itself is directly stored as calibration
values (this gives a channel-dependent passband curve).  In addition a
polynomial is fitted and optionally plotted (this gives a
frequency-dependent passband curve).

(ii) For spectral subbands, polynomials are  fitted  and  optionally
plotted, as a channel-dependent passband curve.
.in -4

The degrees for polynomials are 'da' for amplitude, 'dp' for phase
(defaults 0 and 1). Command STORE should be used next to store the
fitted function in the header of source observations. Both channel
dependent and frequency dependent curves can be stored; Use command
SET RF__PASSBAND FREQUENCY|CHANNEL to apply one or the other.

Option /SPECTRUM supersedes any polynomial given and does use the
data points plotted to derive a bandpass solution. It will factorize
the gains per antenna if SET RF ANTENNA is selected. The bandpass solution
will then be computed by linear interpolation of these data points.

Option /PLOT will plot the polynomial fits over the data. Option /RESET
will reset polynoms in memory.

Option /IGNORE works only in ANTENNA mode. Antennas selected after option
will be ignored in the factorization. This is useful for basebands of the
narrow-correlator when more than 6 antennas were used (with WIDEX).

Option /CROSSED allows to store the RF solution in another memory slot, 
which is used in the case of STORE RF /POLARISATION (see associated HELP).


.ti -4
2 SKYDIP
.ti +4
CLIC\SOLVE SKYDIP [TREC|EFF] [/PLOT] 

Compute receiver temperature TREC or antenna forward efficiency EFF
from skydip scan. Default is EFF. All skydip scans in the current
index are solved.  A graphic display of the solution can be plotted
using the /PLOT option. "SET Y TOTAL" must have been entered before
solving the skydip, to force the software to use the total power
measurements (otherwise, autocorrelations will be used). One should
select a baseband first (see SET BBAND).

The resulting receiver temperatures and forward efficiencies are
available in the variables T__REC and FORWARD__EFF, providing the
command "VARIABLE ATMOSPHERE ON" has been issued.

.ti -4
2 TOTAL
.ti +4
CLIC\SOLVE TOTAL [beam] [/PLOT] [/COMPRESS time__max] [/PRINT]
.ti +4
[/OUTPUT filename [NEW|APPEND] [FLUX] [TPOINT]] 

Find pointing corrections from POINTING scans, but using the total
power from each antenna.  All pointing scans in the current index are
processed by a gaussian fit. The fits may be displayed with option
/PLOT.

The option /COMPRESS may be used to average data in a given time
interval before processing, to improve the signal-to-noise ratio.
Default is 4 seconds. *** option temporarily disabled ***

The presence of option /PRINT produces a procedure file
(INTER__OBS:pointing.obs), to be used in OBS for introducing the
fitted pointing offset.

The results may also be written on an output ASCII file if /OUTPUT is
given.  The file is given extension .lis by default; a new file is
opened except if APPEND is given as a second argument of option
/OUTPUT. The file is by default in a format suitable for the
determination of a pointing model (program POINT at BURE). The
presence of optional argument FLUX changes the output format for the
determination of relative fluxes (by ASTRO). With argument TPOINT, the
output is written in a format suitable for processing by the TPOINT
program.

.ti -4
1 STORE
.ti +4
CLIC\STORE Keyword

Writes calibration (or edition) data in the output file.  All scans
in  the  current  index  are  processed.  

.ti -4
2 AMPLITUDE
.ti +4
CLIC\STORE AMPLITUDE [/BAND LSB|USB|DSB] [/SELF] 
.ti +20
[/POLAR HORIZONTAL|VERTICAL|BOTH]

Store the amplitude calibration determined by the last SOLVE
AMPLITUDE.

One calibration curve is stored for each sideband.  With option "/BAND
code", one may use the calibration curve determined with one of the
sidebands (`code' is UPPER or USB, LOWER or LSB, or AVERAGE or DSB),
to calibrate both sidebands. With option /POLAR, one may use the calibration
curve determined with one of the polarizations.

With option "/SELF", the calibration stored will not be the
calibration curve (as determined from the last SOLVE AMPLITUDE
command) but, for each record, a value derived directly from the
data. The solution is computed independently for each sideband and each
polarization by selecting the matching spectral windows before
averaging, so USB/LSB and H/V values are stored separately. This
provides a simple, easy way to self-calibrate data taken on strong
continuum sources (quasars).

STORE AMPLITUDE and STORE PHASE can be performed simultaneously
using STORE AMPLITUDE PHASE [/BAND code] [/SELF] [/RECEIVER irec]
(the /RECEIVER option has no meaning for amplitudes).

.ti -4
2 CORRECTION
.ti +4
CLIC\STORE CORRECTION [GOOD|BAD|AUTO|SELF [tmin]] [/RECEIVER irec] [/ANTENNA a1 ...] [/FRACTION fraction]

Store in the header of each scan (of the current index) the
information whether the atmospheric phase correction is or not
declared valid, and should be actually applied when SET PHASE ATM is
selected. This is an antenna-based flag.

.in +4
.ti -2
- GOOD: the atmospheric phase correction is to be used.

.ti -2
- BAD: the atmospheric phase correction is not to be used.

.ti -2
- AUTO [tmin]: that information is determined on the phase calibrators 
(type PHASE), by comparing the scan-averaged amplitudes with and without 
the correction. This information is then propagated to the neighbouring
source observations (type OBJECT), in a +- tmin minutes time window.
`tmin' defaults to 15 minutes. 

.ti -2
- SELF: that information is determined on the source, whatever its
type may be, by comparing its amplitude with and without the
correction. This will produce random result if the source has no 
continuum emission.

.ti -2
- STORE CORRECTION /RECEIVER irec: the validity  of the correction
from Receiver 'irec' is used (useful to transfer the correction
validity from one frequency to the other).
.in -4

With option /ANTENNA a1 a2 ..., only the specified antennas are
considered. The correction validity for other antennas is not
modified.

With option /FRACTION fraction, fraction of amplitude will replace the noise
in estimating if uncorrected is better than corrected.

.ti -4
2 FLAG
.ti +4
CLIC\STORE FLAG f1 f2 ...  [/ANTENNA a1 a2 ...   ]  
.ti +4
[/BASELINE b1 b2 ...] [/RESET] [/MEMORY]

Flag all data in the current index according to the parameters  and
option  specified.   

Supported flag names are:

.nf
- C001 to C136 for bad individual continuum correlator subbands
- L001 to L136 for bad individual spectral correlator subbands
- DATA for bad data
- TSYS for too high system temperature (antenna based only)
- LOCK for out of lock local oscillator (antenna based only)
- POINTING for poor pointing (antenna based only)
- SHADOW for antenna being shadowed by another antenna (ant. based only)
- SATURATION for too high total power on a particular antenna
- TIME for time discontinuity
- DOPPLER for doppler discontinuity
- REDU for data reduction 
.fi

Use option /RESET to suppress flags that were accidentally set.

Use option /MEMORY to store flags in memory (not in data). They are lost 
when the session is over.


"STORE FLAG" is equivalent to "MODIFY DATA proc.clic", where the
"proc.clic" procedure contains:
.ti +4
  FLAG f1 f2 ... [/ANTENNA a1 a2 ...] [/BASELINE b1 b2 ...] [/RESET]
.ti +4
  GO WRITE
.ti +0
but it is simpler and faster. All  the  data  records  will  be
flagged.

.ti -4
2 FLUX
.ti +4
CLIC\STORE FLUX

Store the source fluxes and antenna efficiencies determined from a
previous SOLVE FLUX command. Source names, frequencies (within 1GHz)
and dates (within a week) must match. See the SOLVE FLUX and SET FLUX
commands.

.ti -4
2 SPIDX 
.ti +4
CLIC\STORE SPIDX

Store the source spectral indexes determined from a
previous SOLVE SPIDX command. Source names, frequencies (within 1GHz)
and dates (within a week) must match. See the SOLVE SPIDX and SET SPIDX
commands.

.ti -4
2 PHASE
.ti +4
CLIC\STORE PHASE [/BAND LSB|USB|DSB] [/SELF] [/RECEIVER irec]
.ti +25
[/POLAR HORIZONTAL|VERTICAL|BOTH]

Store the phase calibration determined by the last SOLVE PHASE
command.

One calibration curve is stored for each sideband.  With option "/BAND
code", one may use the calibration curve determined with one of the
sidebands (`code' is UPPER or USB, LOWER or LSB, or AVERAGE or DSB),
to calibrate both sidebands. With option /POLAR, one may use the calibration
curve determined with one of the polarizations.

With option "/SELF", the calibration stored will not be the
calibration curve (as determined from the last SOLVE PHASE
command) but, for each record, a value derived directly from the
data. The solution is computed independently for each sideband and each
polarization by selecting the matching spectral windows before
averaging, so USB/LSB and H/V values are stored separately. This
provides a simple, easy way to self-calibrate data taken on strong
continuum sources (quasars).

With option "/RECEIVER irec", the calibration curves solved using data
from receiver "irec" will be stored in parallel with any other
calibration curve.  This phase curve will be selected by giving SET
PHASE EXTERNAL (see this command). In practice, this is used for
Receiver 2 data, for which the calibration curve determined with
Receiver 1 is stored. /BAND may be used in conjunction with /RECEIVER.

STORE PHASE and STORE AMPLITUDE can be performed simultaneously
using STORE AMPLITUDE PHASE [/BAND code] [/SELF] [/RECEIVER irec]
(the /RECEIVER option has no meaning for amplitudes).

.ti -4
2 QUALITY
.ti +4
CLIC\STORE QUALITY code

Store the data quality to be used as a selection criterion. All the
scans in the current index are tagged. Code may be an integer in the
range 0-9, or directly the corresponding quality word:

.in +4
.ti -2
0 Unknown 
.ti -2
1 Excellent 
.ti -2
2 Good
.ti -2
3 Fair
.ti -2
4 Average
.ti -2
5 Poor
.ti -2
6 Bad
.ti -2
7 Awful
.ti -2
8 Worst
.ti -2
9 Deleted
.in -4

.ti -4
2 RF__PASSBAND
.ti +4
CLIC\STORE RF__PASSBAND [/SCAN [/MULTIPLE] [/OVER]] [/POLARISATION]

Store the RF passband calibration curves. Channel dependent and
frequency dependent curves will be simultaneously stored if available.
Caution: RF passbands should be stored only for consistent spectral
correlator configurations.

Option /SCAN allows to store directly the computed passband as an 
extra observation in the hpb file (a file out must be opened). By default, 
CLIC will complain if the file already contains a BANDPASS scan, unless 
the /MULTIPLE option is invoked. Up to 20 solutions can be stored in this
case. Note that any type of bandpass (frequency or spectrum) can be saved
in such a way. Option /OVER allows to overwrite the latest bandpass 
solution instead of writing a new scan.

Option /POLARISATION is used to store RF bandpass solution for the
special NOEMA polarisation scans, which contains 16 subscans. The
16 solutions are computed by mixing the "direct" and "crossed" switches
bandpass solution as appropriate. So one should have done a SOLVE RF
and SOLVE RF /CROSSED beforehand.

.ti -4
1 SG__TABLE

.ti +4
CLIC\SG__TABLE Name [OLD|NEW] 
.ti +4
[/RESAMPLE nc ref val inc code shape width]  [/FFT]
.ti +4
[/FREQUENCY name rest-freq] [/DROP  n1 n2] 
.ti +4
[/NOCHECK [SOURCE|POINTING|PHASE|EPOCH|SCAN]]
.ti +4 
[/ADD Item[s]]
.ti +4
[/POLARIZATION SPLIT|AVERAGE|JOINT]

Prepare a UV Table, in spectral line mode only, but with added
flexibility to store more information compared with the TABLE command.
Polarization is handled in 3 possible ways, the default being AVERAGE.  

Option /POLARIZATION and /ADD control the details of the polarization
handling and of the extra information written. 

See Command TABLE for the other options.

.ti -4 
2 /POLARIZATION


  SPLIT:	 A different visibility for each polarization
  AVERAGE: averaged polarizations before writing
  JOINT:   All channels Polar 1, then All channels polar 2 in visibility

.ti -4
2 /ADD 

.ti +4
CLIC\SG__TABLE Name [OLD|NEW] /ADD Item [Item [...]]

Add some more information columns.  Possible items are 

 U V W DATE TIME IANT JANT  
 which are in principle already present in elements 1 to 7 of the visibilities.

 L__PHASE__OFF M__PHASE__OFF X__POINT__OFF  Y__POINT__OFF
 which indicate the Phase and Pointing offsets (e.g. for mosaics)

 ELEVATION HOUR__ANGLE PARA__ANGLE 
 which can be useful for full polarization measurements
 
 SCAN ON__TIME WEIGHT 
 for bookkeeping
 
 X__POINT__IANT Y__POINT__IANT X__POINT__JANT Y__POINT__JANT  
 the antenna pointing errors (used mostly for simulations...)
 
 RA  DEC  FREQUENCY 
 the Source coordinates and Observing frequency (in Real*8, used for
 multisource UV tables, still very experimental)
 
 STOKES is also a recognized item, but it is handled by the /POLARIZATION option

.ti -4
1 TABLE
.ti +4
CLIC\TABLE Name [OLD|NEW] [/COMPRESS tmax uvmax]
.ti +4
[/RESAMPLE nc ref val inc code shape width]  [/FFT]
.ti +4
[/FREQUENCY name rest-freq] [/DROP  n1 n2] 
.ti +4
[/NOCHECK [SOURCE|POINTING|PHASE|EPOCH|SCAN]] [/MOSAIC]

This command will create an UV data Table from the current index.
'Name' is the file name, the extension defaults to ".UVT".  If 'Name'
is not given, the most recently created table will be extended.  Next
argument may be OLD (default value if not specified) to extend and
existing table, or NEW to create a new table.

The bands and subbands used must have been given by the command SET
SELECTION. The weighting mode can be modified by the command SET
WEIGHTS.

TABLE /RESAMPLE nc ref val inc code [shape width /FFT]

.in +4 
Option /RESAMPLE enables to resample data on a new spectral grid (for
line data).  'nc' is the output number of channels, 'ref' the
reference channel, 'val' the value of velocity or frequency offset
(with respect to the rest frequency) at the reference channel, 'inc'
the resolution, 'code' is "V" if the value 'val' and the resolution 'inc' 
are in velocity units, "F" for frequency units.

The reference channel thus corresponds to the given 'val' velocity, or
to the offset 'val' in MHz from the rest frequency present in the
header or modified by option /FREQUENCY.

Resampling is done by default through linear interpolation of input
channel data. Resampling may also be done (using option /FFT) in
Fourier space by cut-off or extrapolation (by zeroes) of the Fourier
components, after deconvolution by the channel response of the
correlator (due to on-line apodization), and followed by reconvolution
to produce frequency channels of the given 'shape' and 'width'. Allowed
shapes are:
.in +4
.ti -2
TBox = a box in delay space (unapodized correlator)
.ti -2
Ppar = a parabola in delay space (apodized correlator) (the default)
.ti -2
FBox = a box in frequency space (square filter)
.ti -2
FTri = a triangle in frequency space (Hanning smoothed square filter)
.in -4
The width is the channel width in units of channel separation (default 1).

Option /FFT is not recommended when joining together several subbands
to produce a single spectrum, with a limited number of broad channels.
In those cases using the FFT could produce a spectrum with "holes" at
the points between subbands with limited overlap.
.in -4 

TABLE /FREQUENCY  name rest-freq

.in +4
Option /FREQUENCY is used to redefine the rest frequency (in MHz) and
line name for the output table.  The velocity scale is computed
accordingly.  This rest frequency will correspond to the reference
channel in option RESAMPLE.  
.in -4

TABLE /NOCHECK [SOURCE|POINTING|PHASE|EPOCH|SCAN]

.in +4 
When processing each scan, CLIC checks whether a number of position
parameters are consistent with those defined in the table
header. Option /NOCHECK allows to switch off this checking.  Arguments
can be given to switch off only part of the parameters (SOURCE name,
POINTING direction, PHASE center, EPOCH of coordinates). This option
is intended for building tables with inconsistent parameters (typical
exemple is a different source name...). It is potentially dangerous 
and is to be used with caution.  
.in -4

TABLE /DROP n1 n2 --- THIS OPTION IS OBSOLETE

.in +4
Option /DROP enables to drop the first 'n1' and last 'n2'  channels
in each subband of the OLD spectral correlator. For the NEW spectral 
correlator (data taken since summer 1992), it is replaced by the commands
SET GIBBS and SET DROP.
.in -4

TABLE /COMPRESS tmax uvmax

.in +4
Option /COMPRESS is used to compress the data  before  writing  the
table.   This  works like the COMPRESS command, but no intermediate file
is written. Very seldom used.
.in -4

TABLE /MOSAIC

.in +4
Option /MOSAIC is used to add extra offset columns for processing
of mosaics.

.in -4

.ti -4
2 UVTABLE
.ti +4
UV Table format

A UV table is a file in the Gildas Data Format, of dimension 2. 
Each column corresponds to a visibility data point. Lines contain
respectively:

.in +4
.ti -2
1.  U in meters
.ti -2
2.  V in meters
.ti -2
3.  W in meters
.ti -2
4.  Observation date (integer CLIC Day Number)
.ti -2
5.  Time in seconds since above date
.ti -2
6.  Number of start antenna
.ti -2
7.  Number of end antenna
.ti -2
8.  First frequency point (real part)
.ti -2
9.  First frequency point (imaginary part)
.ti -2
10.  First frequency point (weight)
.ti -2
11.  Same for second frequency point, and so on.
.in -4

See the SET WEIGHTS command to select the weighting mode.  The first
dimension is then the 3 * Nchan + 7, for Nchan frequency channels. The
second dimension is the number of UV points measured.

.ti -4
1 TAG
.ti +4
CLIC\TAG Quality__Code List__of__Observations

Attributes a quality to a given list of Observations.  Quality__Code
is an integer in the range 0-9, and the recommended quality scale is

.in +4
.ti -2
0 Unknown 
.ti -2
1 Excellent 
.ti -2
2 Good
.ti -2
3 Fair
.ti -2
4 Average
.ti -2
5 Poor
.ti -2
6 Bad
.ti -2
7 Awful
.ti -2
8 Worst
.ti -2
9 Deleted
.in -4

The operation is immediate  and  occurs  in  the  OUTPUT  file  for  all
versions  of  all  Observations  specified  in  the list.  If no list is
given, the R  memory  is  attributed  the  specified  quality.   A  FIND
operation  will  only  select  Observations of quality better than (i.e.
less or equal to) the quality specified by the SET QUALITY  command,  or
in the /QUALITY option.

.ti -4
1 VARIABLES
.ti +4
CLIC\VARIABLES group ON|OFF

This command is used to create/delete CLIC variables corresponding to
header information. Several groups of variables are available,
corresponding to sections in the scan headers.

.ti +2
READ__WRITE     Input/Output file information (Global)
.ti +2
GENERAL        General information (Scan based)
.ti +2
POSITION       Source related information (Scan based)
.ti +2
CONFIG         Array configuration related information (Scan based)
.ti +2
RF__SETUP       Receiver related information (Scan based)
.ti +2
CONTINUUM      Continuum correlator related information (Scan based)
.ti +2
LINE           Spectral correlator related information (Scan based)
.ti +2
SCANNING       Special scanning information (Record based)
.ti +2
ATMOSPHERE     Atm. calibration parameters and results (Scan based)
.ti +2
MONITOR        Total power monitor information (Scan based)
.ti +2
WVR            Water Vapor Radiometer information (Scan based)
.ti +2
DESCRIPTOR     Data descriptor information (Scan based)
.ti +2
DATA__HEADER    Data header information (Record based)
.ti +2
DATA__RECORD    Data values (Record based)
.ti +2
INDEX          Current index variables
.ti +2
ALMA           ALMA specific information
.ti +2
AIC            Antenna Instrumental Calibration (Scan based)
.ti +2
SIZE           Dimensioning parameters
.ti +2
INSTRUMENT     Instrumental parameters
.ti +2
SPW            Spectral windows parameters

Scan- or record-based variables refer to the last scan or record that
has been read (explicitely by GET/RECORD, or implicitely by PLOT or
other commands).

.ti -4
2 READ__WRITE
.ti +4
CLIC\VARIABLES READ__WRITE ON|OFF

Input/Output file information (Global).

.ti +2
IN__FILE          Name if input file
.ti +2
OUT__FILE         Name of output file
.ti +2
INBLOC           Block of observation in input file
.ti +2
IDATA            Address od data section in input observation
.ti +2
INSEC            Number of sections in header
.ti +2
INEXT            Next available block in input file
.ti +2
ONEXT            Next available block in output file
.ti +2
IXNUM            Index number of current observation in input file
.ti +2
ISEC [INSEC]     Header sections
.ti +2
ILEN [INSEC]     Length of header section (words)
.ti +2
IADD [INSEC]     Addresses of header sections (words)
.ti +2
IVERSION         Observation version (header)
.ti +2
DVERSION         Observation version (data if applicable)
.ti +2
IXNEXT           Next available entry in input file index
.ti +2
OXNEXT           Next available entry in output file index
.ti +2
CXNEXT           Next available entry in current index
.ti +2
INWORD           Number of words in current observation
.ti +2
IDATAL           Length (words) of data section
.ti +2
MODIFY           (Logical) data is open for modify
.ti +2
SHARE            (Logical) Output file is shared
.ti +2
IX__NUM   [ ]     Observation numbers in input file index
.ti +2
IX__BLOC  [ ]     Blocks numbers of observations in input file 
.ti +2
OX__NUM   [ ]     Observation numbers in output file index
.ti +2
OX__BLOC  [ ]     Blocks numbers of observations in output file 

The following additional variables are defined by the command FIND:

.ti +2
FOUND            Number of observations in current index 

.ti -4
2 GENERAL
.ti +4
CLIC\VARIABLES GENERAL ON|OFF

General information (Scan based).

.ti +2
TELESCOPE        Telescope name
.ti +2
RECEIVER         Receiver number
.ti +2
CONFIGURATION    Interferometer configuration 
.ti +2
NUMBER           Observation number
.ti +2
VERSION          Observation version number
.ti +2
DOBS             Day of observation (internal format)
.ti +2
DATE__OBSERVED    Day of observation (in clear)
.ti +2
DRED             Day of last reduction (internal format)
.ti +2
DATE__REDUCED     Day of last reduction (in clear)
.ti +2
DATATYPE         Type of observation (4 for interferometer data)
.ti +2
IQUAL            Quality of observation (0-9)
.ti +2
QUALITY          Quality of observation (Excellent, ... Awful)
.ti +2
SCAN             Scan number
.ti +2
UTOBS            Time of observation (radians!)
.ti +2
TIME__OBSERVED    Time of observation (hh:mm:ss.ss)
.ti +2
LSTOBS           Sidereal time of observation (radians)
.ti +2
AZIMUTH          Azimuth of source direction (radians)
.ti +2
ELEVATION        Elevation of observation (radians)
.ti +2
AIR__MASS         Airmass of observation
.ti +2
TSYS             System temperature (K)
.ti +2
TIME             Integration time (minutes)
.ti +2
PROJECT          Project name
.ti +2
PROC             Procedure used (internal format)
.ti +2
PROCEDURE        Procedure used (in clear)
.ti +2
TYPE__OFF         Type of offsets
.ti +2
N__BOXES          Number of plotted boxes
.ti +2
NEW__RECEIVERS    Logical indicating if receiver are from > 2006

.ti -4
2 POSITION
.ti +4
CLIC\VARIABLES POSITION ON|OFF

Source related information (Scan based).

.ti +2
SOURCE           Source name
.ti +2
LAMBDA           Source longitude-like coordinate (radians)
.ti +2
BETA             Source latitude-like coordinate (radians)
.ti +2
OFF__LAMBDA       Offset in lambda (radians)
.ti +2
OFF__BETA         Offset in beta (radians)
.ti +2
EPOCH            Epoch of coordinates (if equatorial)
.ti +2
PROJECTION       Projection used for offsets
.ti +2
FOCUS            Focus position used
.ti +2
FLUX             Source flux (Jy) for calibrators
.ti +2
SPIDX            Source spectral index for calibrators
.ti +2
TYPE__COORD       Type of coordinates   

.ti -4
2 CONFIG
.ti +4
CLIC\VARIABLES CONFIG ON|OFF

Array configuration related information (Scan based).

.ti +2
NANT                     Number of antennas
.ti +2
NBAS                     Number of baselines
.ti +2
ITYPE                    Type of observation (Object:1 or Phase:2)
.ti +2
HOUR__ANGLE               Hour angle of observation (hours)
.ti +2
STATION        [NANT]    Positions of antennas
.ti +2
PHYS__ANT       [NANT]    Antenna physical numbers
.ti +2
CORR__INPUT     [NANT]    Correlator input connected for each antenna
.ti +2
START__ANTENNA  [NBAS]    First antenna of baseline
.ti +2
END__ANTENNA    [NBAS]    Second antenna of baseline
.ti +2
BASELINE     [3,NBAS]    Coordinates of baselines (meters)
.ti +2
ANTENNA      [3,NANT]    Coordinates of antennas (meters)
.ti +2
AXES__OFFSET    [NANT]    Offsets of El axis from Az axes (meters)
.ti +2
PHLO1          [NANT]    L01 phase
.ti +2
PHLO3          [NANT]    L03 phase
.ti +2
NBAND__WIDEX              Number of WIDEX units

.ti -4
2 RF__SETUP
.ti +4
CLIC\VARIABLES RF__SETUP ON|OFF

Receiver related information (Scan based).

.ti +2
LINE             Line name (in OBS)
.ti +2
FREQUENCY        Rest Frequency (in OBS) (MHz)
.ti +2
ISB              Side band (1:upper, -1:lower)
.ti +2
LOCK             Lock
.ti +2
FLO1             Frequency of First LO (MHz)
.ti +2
FLO1__REF         Frequency of First LO reference (MHz)
.ti +2
FIF1             First intermediate frequency (MHz)
.ti +2
VELOCITY         Velocity entered in OBS (km/s)
.ti +2
TYPE__VEL         Velocity type
.ti +2
DOPPLER          Doppler correction factor (v/c)
.ti +2
N__IF                  Number of IFs
.ti +2
IFNAME [N__IF]         IF name
.ti +2
KIF    [N__IF]        "Physical" IF number
.ti +2
R__IFATTN [NANT,N__IF]  IF attenuation (dB)    
.ti +2
R__NBB                 Number of basebands
.ti +2
R__BBNAME [R__NBB]      Baseband names
.ti +2
R__KBB [R__NBB]         "Physical" baseband numbers
.ti +2
R__MAPBB  [NANT,R__NBB] Baseband indexing 
.ti +2
R__MAPPOL [NANT,R__NBB] Baseband polarisation



.ti -4
2 CONTINUUM
.ti +4
CLIC\VARIABLES CONTINUUM ON|OFF

Continuum correlator related information (Scan based).

.ti +2
N__SIDEBANDS      Number of present sidebands
.ti +2
N__SUB__BANDS      Number of continuum sub-bands
.ti +2
NCDAT            Total number of channels (sidebands x subbands)
.ti +2
CRCH [2]         Reference channel for sideband
.ti +2
CVOFF [2]        Velocity for sideband
.ti +2
CVRES [2]        Velocity resolution
.ti +2
CRFOFF [2]       Rest frequency (MHz)
.ti +2
CRFRES [2]       Frequency resolution
.ti +2
CNAM__U           Line name for Upper side band
.ti +2
CNAM__L           Line name for Lower side band
.ti +2
CFCEN [10]       Center frequency for subband (MHz)
.ti +2
CFWID [10]       Width of subband (MHz)

.ti -4
2 LINE
.ti +4
CLIC\VARIABLES LINE ON|OFF

Spectral correlator related information (Scan based).

.ti +2
N__LINE__BANDS             Number of line subbands
.ti +2
FOURIER                  (Logical) FFT done, data in frequency space
.ti +2
TOTAL__CHANNELS           Total number of line channels
.ti +2
N__CHANNELS     [NSUBB]   Number of channels in subband
.ti +2
FIRST__CHANNEL  [NSUBB]   First channel in subband
.ti +2
LFCEN          [NSUBB]   LO3 frequency (channel 1)
.ti +2
LFRES          [NSUBB]   Frequency resolution (signed)
.ti +2
REF__CHANNEL  [2,NSUBB]   Reference channel for spectrum 
.ti +2
F__RESOLUTION [2,NSUBB]   Frequency resolution
.ti +2
F__OFFSET     [2,NSUBB]   Rest frequency in reference channel
.ti +2
V__RESOLUTION [2,NSUBB]   Velocity resolution
.ti +2
V__OFFSET     [2,NSUBB]   Velocity in reference channel
.ti +2
R__LILEVU  [NSUBB,NANT]   Sampling levels (USB)
.ti +2
R__LILEVL  [NSUBB,NANT]   Sampling levels (LSB)
.ti +2
REF__NUM        [NSUBB]   Spectral window reference channel 
.ti +2 
UNIT__NUMBER    [NSUBB]   Unit "physical" number
.ti +2
R__FLO2         [NSUBB]   LO2 frequency (MHz)
.ti +2
R__BAND2        [NSUBB]   LO2 conversion sign
.ti +2
R__FLO2BIS      [NSUBB]   LO2bis frequency (MHz)
.ti +2
R__BAND2BIS     [NSUBB]   LO2bis conversion sign
.ti +2
R__FLO3         [NSUBB]   LO3 frequency (MHz)
.ti +2
R__FLO4         [NSUBB]   LO4 frequency (MHz)
.ti +2
BAND4          [NSUBB]   Sign of band 4 conversion 
.ti +2
R__LPOLMODE     [NSUBB]   Polarisation mode
.ti +2
R__LPOLENTRY[NANT,NSUBB]  Polarisation connected to spw
.ti +2
R__BB           [NSUBB]   Spectral window baseband
.ti +2
R__IF           [NSUBB]   Spectral window IF
.ti +2
R__SB           [NSUBB]   Spectral window sideband
.ti +2
R__STARTING__CHUNK [NSUBB] Spectral widow starting chunk
.ti +2
R__NB__CHUNK       [NSUBB] Spectral window number of chunk
.ti +2
PHSELECT  [NANT,NSUBB]   Real-time atm. correction (1: TP, 2:WVR)

.ti -4
2 SCANNING
.ti +4
CLIC\VARIABLES SCANNING ON|OFF

Special scanning information (Record based). This is for 
Pointing, Focus, Holography, ...

.ti +2
SCAN__TYPE        Type of special scan (1 focus 2,3 point 4,5 calibr)
.ti +2
MOBIL   [NANT]   Antennas in motion (logical)
.ti +2
COLL__AZ [NANT]   Collimation in azimuth (arc sec)
.ti +2
COLL__EL [NANT]   Collimation in elevation (arc sec)
.ti +2
COR__FOC [NANT]   The Z focus correction in mm

.ti -4
2 ATMOSPHERE
.ti +4
CLIC\VARIABLES ATMOSPHERE ON|OFF

Atmospheric calibration parameters and results (Scan based).

.ti +2
PRESSURE                 Pressure in hectopascals (zero alt.)
.ti +2
AMBIANT__T                Outside temperature (K)
.ti +2
ALTITUDE                 Altitude in kilometers
.ti +2
HUMIDITY                 Humidity in %
.ti +2
WATER          [NANT]    Water content (mm)
.ti +2
TAU__S          [NANT]    Optical depth in signal side band
.ti +2
TATM__S         [NANT]    Temperature of atmosphere in signal side band
.ti +2
TAU__I          [NANT]    Optical depth in image side band
.ti +2
TATM__I         [NANT]    Temperature of atmosphere in image side band
.ti +2
BEAM__EFF       [NANT]    Beam efficiency
.ti +2
FORWARD__EFF    [NANT]    Forward efficiency
.ti +2
T__CHOPPER      [NANT]    Temperature of ambiant load (K)
.ti +2
T__COLD         [NANT]    Temperature of cold load (K)
.ti +2
T__REC          [NANT]    Receiver temperature (K)
.ti +2
GAIN__IMAGE     [NANT]    Gain ratio image/signal
.ti +2
CHOPPER__COUNTS [NANT]    Measured counts on ambiant load
.ti +2
COLD__COUNTS    [NANT]    Measured counts on cold load
.ti +2
SKY__COUNTS     [NANT]    Measured counts on sky
.ti +2
T__SYS__S        [NANT]    System temperature (signal band)
.ti +2
T__SYS__I        [NANT]    System temperature (image band)
.ti +2
CHOPPER__EFF    [NANT]    Chopper efficiency
.ti +2
CAL__MODE       [NANT]    Calibration reduction mode
.ti +2
JY__TO__KEL      [NANT]    Jansky to Kelvin conversion factor
.ti +2
TOTAL__SCALE    [NANT]   Scaling factor for physical total power 
.ti +2
T__CABIN        [NANT]    Temperature in cabin (K)
.ti +2
T__DEWAR      [3,NANT]    Temperatures in dewar (K)  

.ti -4
2 MONITOR
.ti +4
CLIC\VARIABLES MONITOR ON|OFF

Total power monitor information (Scan based).

.ti +2
NREC__MON
.ti +2
FRS__MON
.ti +2
FRI__MON
.ti +2
MAGIC__MON
.ti +2
WATER__MON       [NANT]
.ti +2
TAU__S__MON       [NANT]
.ti +2
TAU__I__MON       [NANT]
.ti +2
TATM__S__MON      [NANT]
.ti +2
TATM__I__MON      [NANT]
.ti +2
FORWARD__EFF__MON [NANT]
.ti +2
T__CHOPPER__MON   [NANT]
.ti +2
T__COLD__MON      [NANT]
.ti +2
T__REC__MON       [NANT]
.ti +2
GAIN__IMAGE__MON  [NANT]
.ti +2
CHOP__COUNTS__MON [NANT]
.ti +2
SKY__COUNTS__MON  [NANT]
.ti +2
COLD__COUNTS__MON [NANT]
.ti +2
T__SYS__MON       [NANT]
.ti +2
CAL__MODE__MON    [NANT]
.ti +2
PATH__MON        [NANT]
.ti +2
TEM__MON         [NANT]
.ti +2
DPATH__MON       [NANT]
.ti +2
OK__MON          [NANT]

.ti -4
2 WVR
.ti +4
CLIC\VARIABLES WVR ON|OFF

Water Vapor Radiometer information (Scan based).

.ti +2
WVRNCH          [NANT]   Number of channels (=3; 0 if no WVR)
.ti +2     
WVRFREQ  [WVRNCH,NANT]   Central frequencies (MHz)
.ti +2
WVRBW    [WVRNCH,NANT]   Bandwidths (MHz)
.ti +2
WVRTAMB         [NANT]   Temp ambient load (K)
.ti +2
WVRTPEL         [NANT]   Temp Peltier cooler (K)
.ti +2
WVRTCAL         [NANT]   Calibration temperature (K)
.ti +2
WVRREF   [WVRNCH,NANT]   Average counts on reference observation
.ti +2
WVRAVER  [WVRNCH,NANT]   Average counts on current observation
.ti +2
WVRAMB   [WVRNCH,NANT]   Average counts on last ambient measurement
.ti +2
WVRTREC  [WVRNCH,NANT]   Receiver temperatures (K)
.ti +2
WVRLABTREC [WVRNCH,NANT]  
.ti +2
WVRLABTCAL [WVRNCH,NANT]   
.ti +2
WVRLABTDIO [WVRNCH,NANT]   
.ti +2
WVRFEFF  [WVRNCH,NANT]   Coupling factor
.ti +2
WVRMODE         [NANT]   Calibration mode
.ti +2
WVRH2O          [NANT]   Precipitable water vapor (mm)
.ti +2
WVRPATH         [NANT]   Water vapor pathlength (mum)
.ti +2
WVRTSYS  [WVRNCH,NANT]   System temperature (K)
.ti +2
WVRDPATH [WVRNCH,NANT]   K to H2O vap. pathlength (model, mum/K)
.ti +2
WVRFPATH [WVRNCH,NANT]   K to H2O vap. pathlength (empirical, mum/K)
.ti +2
WVRLIQ   [WVRNCH,NANT]   K to H2O liquid emission (K/K)
.ti +2
WVRDCLOUD[WVRNCH,NANT]   K to H2O liquid pathlength (mum/K)
.ti +2
WVRTATM         [NANT]   Temperature of atmosphere (K)
.ti +2
WVRQUAL         [NANT]   Quality code
.ti +2
WVRAVERTIME              Averaging time for wvr (s)

.ti -4
2 DESCRIPTOR
.ti +4
CLIC\VARIABLES DESCRIPTOR ON|OFF

Data descriptor information (Scan based).

.ti +2
N__DUMPS                  Number of records
.ti +2
HEADER__LENGTH            Length of data header (words)
.ti +2
CONT__LENGTH              Length of continuum data (words)
.ti +2
LINE__LENGTH              Length of line data (words)

.ti -4
2 DATA__HEADER
.ti +4
CLIC\VARIABLES DATA__HEADER ON|OFF

Data header information (Record based).

.ti +2
DH__DUMP                  Record number
.ti +2
DH__OBS                   Date of observation (in internal format)
.ti +2
DH__DATE                  Date of observation (in clear)
.ti +2
DH__INTEG                 Integration time in seconds
.ti +2
DH__SVEC[3]               EQ coordinates of source direction
.ti +2
DH__AFLAG      [NANT]     Antenna flag word
.ti +2
DH__TOTAL      [NANT]     Total power
.ti +2
DH__DELCON     [NANT]     Delay used for continuum correlator (ns)
.ti +2
DH__DELLIN     [NANT]     Delay used for line correlator (ns)
.ti +2
DH__DELAYC     [NANT]     Computed delay (ns)
.ti +2
DH__DELAY      [NANT]     Delay offset (ns)
.ti +2
DH__PHASEC     [NANT]     Computed LO1 phase 
.ti +2
DH__PHASE      [NANT]     LO1 Phase offset
.ti +2
DH__RATEC      [NANT]     Computed fringe rate
.ti +2
DH__CABLE      [NANT]     Phase of IF cable (at LO2 frequency)
.ti +2
DH__OFFFOC     [NANT]     Focus offset (mm)
.ti +2
DH__OFFLAM     [NANT]     Azimuth offset (arc sec) in pointing scans
.ti +2
DH__OFFBET     [NANT]     Elevation offset (arc sec) in pointing scans
.ti +2
DH__UVM      [2,NBAS]     U and V for baseline (meters)
.ti +2
DH__RMSPE    [2,NANT]     AZ and EL pointing errors rms *arc sec.)
.ti +2
DH__UTC                   UT Time (sec)
.ti +2
DH__TIME                  UT Time (hh:mm:ss.ss)
.ti +2
DH__ATFAC    [2,NANT]     Atm. calibration factor [sideband,ant] (K)
.ti +2
DH__BFLAG      [NBAS]     Baseline Flag word
.ti +2
DH__INFAC  [2,2,NBAS]     Instrumental factor [real/imag,upp/low,base]
.ti +2
DH__WVR [WVRNCH,NANT]     Counts of each WVR channel                         
.ti +2
DH__WVRSTAT    [NANT]     WVR status word
.ti +2
DH__TEST0        [20]     Test variables
.ti +2
DH__TEST1   [20,NANT]     Test variables (by antenna).
.ti +2
DH__GAMME  [    NANT]     Gamme (obsolete)
.ti +2
DH__RMSPHA   [2,NBAS]     Phase rms
.ti +2
DH__RMSAMP   [2,NBAS]     Amplitude rms
.ti +2
AMPFAC__L  [2,2,NBAS]    
.ti +2
AMPFAC__U  [2,2,NBAS]
.ti +2
DH__ACTP          [2,NANT,NSUBB]   Autocorrelation total power
.ti +2
DH__ANTTP             [N__IF,NANT]  Warm-IF total power (dBm)
.ti +2
DH__SAFLAG        [2*NSUBB,NANT]   Antenna spectral flags
.ti +2
DH__SBFLAG        [2*NSUBB,NBAS]   Baseline spectral flags
.ti +2
IS__SAFLAG                [NANT]   Is there any antenna spectral flag
.ti +2
IS__SBFLAG                [NBAS]   Is there any baseline spectral flag
.ti +2
DH__CABLE__ALTERNATE       [NANT]   Cable phase for the other reference
.ti +2
DH__NTIME                          Number of recorder time parameters
.ti +2
DH__TIME__MONITORING   [DH__NTIME]   Time parameters
.ti +2
DH__INCLI               [NANT,2]   Station inclination (X,Y)
.ti +2  
DH__INCLI__TEMP            [NANT]   Inclinometer temperature (C)
.ti +2
DH__TILFOC              [NANT,3]   Subreflector tilt (/X,/Y,/Z) 
.ti +2
DH__OFFFOC__XY           [NANT,2]   Subreflector offset (X,Y)

.ti -4
2 DATA__RECORD
.ti +4
CLIC\VARIABLES DATA__RECORD ON|OFF

Data values (Record based).

.ti +2
DATA__C [CONT__LENGTH]     Continuum data
.ti +2
DATA__L [LINE__LENGTH]     Line data

The following additional variables are computed by command MINMAX:

.ti +2
C__AMPMAX__U [NBAS]        Maximum amplitude, continuum, USB              
.ti +2
L__AMPMAX__U [NBAS]        Maximum amplitude, line, USB              
.ti +2
C__AMPMAX__L [NBAS]        Maximum amplitude, continuum, LSB              
.ti +2
L__AMPMAX__L [NBAS]        Maximum amplitude, line, LSB              
.ti +2
C__AMPMIN__U [NBAS]        Minimum amplitude, continuum, USB              
.ti +2
L__AMPMIN__U [NBAS]        Minimum amplitude, line, USB              
.ti +2
C__AMPMIN__L [NBAS]        Minimum amplitude, continuum, LSB              
.ti +2
L__AMPMIN__L [NBAS]        Minimum amplitude, line, LSB              

.ti -4
2 INDEX
.ti +4
CLIC\VARIABLES INDEX ON|OFF

Index variables
.ti +2
CX__NUM   [FOUND]     Observation numbers in current index
.ti +2
CX__BLOC  [FOUND]     Blocks numbers of observations in current index

.ti -4
2 AIC
.ti +4
CLIC\VARIABLES AIC ON|OFF

Index variables
.ti +2
AIC                         Has a solution been stored
.ti +2
AICDEG                      Solution degree
.ti +2
AICPHA [2,2,NANT,AICDEG]    Phase solution (pol,sb,nant,deg)
.ti +2
AICAMP [2,2,NANT,AICDEG]    Amplitude solution (pol,sb,nant,deg)


.ti -4
2 SIZE
.ti +4
CLIC\VARIABLES SIZE ON|OFF

Dimensioning parameter.
.ti +2
MAXANT                    CLIC maximum number of antennas
.ti +2
MAXBAS                    CLIC maximum number of baselines
.ti +2
NSFLAG                    Maximum numbers of spectral windows

.ti -4
2 INSTRUMENT
.ti +4
CLIC\VARIABLES INSTRUMENT ON|OFF

Instrument parameters.
.ti +2
HIQ__ATTEN        [NANT,2]       High-Q cables attenuation (dB)
.ti +2
LASER__LEVEL   [NANT,N__IF]       Optical link power (V)
.ti +2
WIDEX__TEMPERATURE      [4]       Widex temperatures C()

.ti -4
2 SPW
.ti +4
CLIC\VARIABLES SPW ON|OFF

Spectral window parameters.
.ti +2
SPW%NSPW
.ti +2
SPW%NAME  [NSPW]  Spectral window name
.ti +2
SPW%TOPO  [NSPW]  Spectral window topocentric ref frequency (MHz)
.ti +2
SPW%FREQ  [NSPW]  Spectral window rest frequency (MHz)
.ti +2
SPW%BW    [NSPW]  Spectral window bandwidth (MHz)
.ti +2
SPW%POL   [NSPW]  Spectral window polarisation (1:H, 2:V)
.ti +2 
SPW%SB    [NSPW]  Spectral window sideband 

.ti -4
1 WVR
.ti +4
CLIC\WVR [/CMODE wvrmode wvrcpol] [/NOWRITE]

This command is used to prepare the atmospheric phase correction based
on the 22 GHz Water Vapor Radiometers (WVR). It process all scans in
the current index and performs two operations.

First, it processes the WVR calibration scans (CWVR) to compute
receiver and calibration temperatures of each radiometer. Option
/CMODE is used to specify the WVR calibration mode: the 'wvrmode'
parameter can be equal to: 
.in +4 
.ti -2 
- TR__GE: Trec + gain external 
.ti -2 
- LAB 
.ti -2 
- TREC 
.ti -2 
- DIODE 
.ti -2 
- NOCAL: no calibration, for test purposes only 
.in -4
 
The second argument of /CMODE is 'wvrcpol' which gives the degree of
the poynomial fit removed from the data. 
Default value are: wvrmode = TREC, and wvrcpol = 0.

.ti -4
1 ENDOFHELP
