Next: Worked example
Up: The graphics translation file
Previous: SIZE1, SIZE2 and SIZE3
The name of the column to be used to label each object.
If the graphics translation file simply consists of a set of specifiers
for the above items they will be applied to all the objects in the list.
Often this approach will be adequate. However, sometimes it will be
desired to plot different objects in different ways (for example with
different symbols or colours), depending on whether or not they meet
some criteria. This behaviour is achieved by enclosing the definitions
for the graphics attributes within a set of clauses, where each clause
defines some aspect of the symbol to be used for objects which meet the
criteria. The syntax is:
IF condition
ELSE IF condition
ELSE IF condition
ELSE
END IF
condition is the condition, expressed in terms of columns in the
targets list, which objects must satisfy to be plotted in the particular
way. An example might be `MAG .LT. 12.0' to plot objects brighter
than 12th magnitude in a given way. The following points apply.
- An arbitrary number of clauses are permitted; there is no upper
limit.
- The optional ELSE is a special clause which is applied
to any objects in the targets list which do not satisfy any of the
other cases. There is no condition attached to ELSE. If
ELSE is omitted then objects which satisfy none of the cases
are not written to the output target list (and hence are not
plotted).
- Because the conditions defining the set of objects to be included
in each case are not necessarily mutually exclusive it is technically
possible for a given object to match more than one case. In this event
it will be plotted in the manner prescribed by the first case it
matches.
- Any graphics attributes defined outside an IF ...END
IF apply to all the objects plotted.
- An arbitrary number of separate IF ...END IF constructs
can be included in the graphics translation file. Typically, more than
one might be used to set up different aspects of the plotting symbol
(for example, one construct to set the plotting colour, based on the
photometric colour of the object and a second to set the symbol shape
based on the object classification).
- However, IF ...END IF constructs may not be
nested.
- The two words `ELSE IF' may be separated by zero, one
or an arbitrary number of spaces; similarly the two words `END IF'
may be separated by zero, one or an arbitrary number of spaces.
- The LABEL item cannot appear inside a clause. If present it
must be outside any clauses and refers to the entire target list.
Next: Worked example
Up: The graphics translation file
Previous: SIZE1, SIZE2 and SIZE3
CURSA Catalogue and Table Manipulation Applications
Starlink User Note 190
A.C. Davenhall
4th November 2001
E-mail:starlink@jiscmail.ac.uk
Copyright © 2001 Council for the Central Laboratory of the Research Councils