next up previous 63
Next: Example
Up: The Scripts
Previous: Script source code.


Process Compressed Files

Script doapp.csh allows you to apply an application to a series of compressed files. It is useful if disk space is scarce. The files are assumed to have been compressed with the Unix utility compress. Each file is, in turn, decompressed, processed and recompressed. In the script provided application histpeak in ESP is used to determine the median value of the image and this value is output to a text file. This effect is achieved by writing histpeak's output to a temporary file and then using the Unix utilities grep and awk to extract the details required.

It is relatively straightforward to change doapp.csh to perform some other processing. For example, script dostats.csh is a modified version which uses KAPPA application stats to find the mean of each image. Using the Unix command diff on scripts doapp.csh and dostats.csh will show the lines that need to be changed to produce a modified script which performs some other processing.

The input for either script consists of the names of one or more files to be processed (wild-cards are permitted) and the name of the output text file.


Subsections

next up previous 63
Next: Example
Up: The Scripts
Previous: Script source code.

The 2-D CCD Data Reduction Cookbook
Starlink Cookbook 5
A.C. Davenhall, G.J. Privett & M.B. Taylor
16th August 2001
E-mail:starlink@jiscmail.ac.uk

Copyright © 2001 Council for the Central Laboratory of the Research Councils