STScI Logo

names noao.onedspec



names -- Generate image names from a root and a range descriptor


names input records


The root file name for the input records to be calibrated.
The range of spectra to be included in the calibration operation. Each range item will be appended to the root name to form an image file name.
append = ""
If not a null string, this character string will be appended to all the generated image names. This allows for a specification of image sections.
check = no
If set to yes, a check is made that each name implied by the range specification has at least an image header. The pixel file is not checked. If set to no, then all possible image names are generated even if no image exists.


A sequence of image names is generated from the input root file name and the range description by appending the possible range values to the root in the form "root.nnnn". At least four digits will follow the root.

If an append string is specified, this is added to the image name as well.

The generated image names are written to STDOUT, but may be redirected to a file for further use.


The following will generate names of the form nite1.0001, nite1.0002 ... nite1.0010 and place the list in the file nite1.lst.

	cl> names nite1 1-10 >nite1.lst

The next example uses the append option to specify that only the first 512 pixels of each image (spectrum) are to used in the image name.

	cl> names nite1 1-10 append="[1:512]" >nite1.lst


This task is unchanged.


The append option is only useful for adding image sections since it is added after the ONEDSPEC name is generated. Appending other strings produces names such as root.0012str which are not recognized by the package.

Source Code · Search Form · STSDAS