KPG1_WRLST

Writes a set of positions to a text file as a CAT catalogue

Description:

This routine saves a set of positions in a text file as a CAT catalogue (see SUN/181). Information describing associated co-ordinate Frames can also be stored in the file as textual information, allowing subsequent applications to interpret the positions. Files written with this routine can be read using KPG1_RDLST (and also XCATVIEW etc.).

The positions are stored in the file in a Frame selected by the user using hardwired parameters CATFRAME and CATEPOCH. This Frame defaults to a SKY Frame if present, otherwise a PIXEL Frame if present, otherwise the original Base Frame within the supplied FrameSet. The positions can be supplied within any of the Frames in the FrameSet and will be Mapped into the required Frame if necessary.

If the ID atttribute of the FrameSet is set to " FIXED_BASE" , then the user is not allowed to change the base Frame using parameters CATFRAME and CATEPOCH.

See also KPG1_WRTAB, which is like this routine but allows a textual label to be associated with each position.

Invocation

CALL KPG1_WRLST( PARAM, ARRDIM, NPOS, NAX, POS, IFRM, IWCS, TITLE, ID0, IDENTS, NULL, STATUS )

Arguments

PARAM = CHARACTER ( ) (Given)
The name of the parameter to use.
ARRDIM = INTEGER (Given)
The size of the first dimension of the positions array. This must be larger than or equal to NPOS.
NPOS = INTEGER (Given)
The number of positions to store in the file.
NAX = INTEGER (Given)
The number of axes in the Frame specified by IFRM.
POS( ARRDIM, NAX ) = DOUBLE PRECISION (Given)
The positions to store in the file. POS( I, J ) should give the axis J value for position I.
IFRM = INTEGER (Given)
The index of the Frame within IWCS to which the supplied positions relate. Can be AST__BASE or AST__CURRENT.
IWCS = INTEGER (Given)
A pointer to an AST FrameSet to store with the positions.
TITLE = CHARACTER ( ) (Given)
A title to store at the top of the text file. Ignored if blank.
ID0 = INTEGER (Given)
The integer identifier value to associate with the first supplied position. Identifiers for subsequent positions increase by 1 for each position. If this is supplied less than or equal to zero, then its value is ignored and the identifiers supplied in array IDENTS are used instead.
IDENTS( NPOS ) = INTEGER (Given)
The individual integer identifiers to associate with each position. Only accessed if ID0 is less than or equal to zero.
NULL = LOGICAL (Given)
Is the user allowed to supply a null value? If so, the error status will be annulled before returning.
STATUS = INTEGER (Given and Returned)
The global status.