SKIP directive

Skips lines in input or output files.


Options

CHANNEL = scalar
Channel number of file; default current channel of the specified type

FILETYPE = string
Type of the file concerned (input, output); default inpu

STYLE = string
Style to use when skipping output (plaintext, formatted); default * uses the current style of the channel


Parameter

    identifiers
How many lines to skip; for input files, a text means skip until the contents of the text have been found, further input is then taken from the following line


Description

SKIP can be used with either input or output files. The FILETYPE and CHANNEL options indicate which file is to be skipped. By default this is the current input channel.

   For input files you can skip over unwanted lines, which might be comments describing the data that is to follow, or might be some statements that you do not want to use in your current job. You can skip a specified number of lines, n say, by setting the parameter to a scalar containing the value n. Alternatively, you can skip everything up to and including a particular string of characters by setting the parameter to a text containing that string. For example,

SKIP [CHANNEL=2] 'Section 2'

will skip the contents of the input file on channel 2 from the current position until the string Section 2 is found. The next line to be read from channel 2 will then be the one immediately after the line containing Section 2.

   For output files you can use SKIP to print blank lines to separate one section of output from another. You might want to do this if you had set the PRINT option SQUASH=yes to suppress the automatic blank lines within a section of output. For example,

PRINT [CHANNEL=2; IPRINT=*; SQUASH=yes] Heading

SKIP [CHANNEL=2; FILETYPE=output] 2

PRINT [CHANNEL=2; IPRINT=*; SQUASH=yes] Table

places two blank lines between Heading and Table when printing their values to channel 2.

   For an output file that has been opened in a style other than plain text (see OPEN), you can use the STYLE option to control whether the skipping is done in formatted or plain-text styles. If STYLE is not set, the default is to use the current style (as controlled by the OUTPUT directive).

 

Options: CHANNEL, FILETYPE, STYLE.

Parameter: unnamed.