pro nis_recal, LFILE=lfile, CLEAN=clean, HELP=help ;============================================================================= ; ABSTRACT ; "Above the top" level procedure for NIS re-calibration. ; Reads in a list of configuration files and runs niscal on each. Used primarily ; for recalibrating files already calibrated by an older version of niscal. ; Calibrate nis spectral data from FITS format files ; ; INPUTS ; ; SOURCEDIR - directory where NISCAL files are located. Defaults to ; '/project/near/ST/NIS/zen/nis_cal/' or whatever is ; hardcoded in the program body. ; lfile - name of listfile of configuration files to be read. This file ; contains the list of .conf files for each iteration of ; niscal ; clean - toggles erasure of files in output directory before running niscal. ; HELP - entering /help will give information about using nis_cal ; ; ; USES ; strip ; ; HISTORY ; Created: 02/17/00 by N. R. Izenberg ; Modified ; ; NOTES ;============================================================================= ; Main Program if n_elements(help) ne 0 then begin print,"Usage is: niscal, SOURCEDIR=dir, cfile=file, /help" print," sourcedir - contains program directory information" print," Enter manually if the sourcedir environment variable" print," is not in your .cshrc" print," lfile - listfile of configuration files. print," clean - toggles erasure of files in output directory before print," running niscal" goto, helpout endif if n_elements(lfile) eq 0 then lfile = $ "/project/near/ST/NIS/products/config_files/config_filelist.lis" readcol,lfile,FORMAT='A',config_list, skipline=5 lsiz=size(config_list) for i=0,lsiz(1)-1 do begin if not (keyword_set (CLEAN)) then niscal,cfile=config_list(i) else $ niscal,cfile=config_list(i),/clean endfor helpout: end