Making Finding Charts
With WIDL
[TDC Home]  [TDC Search] [OIR Home]

widl is a package of idl procedures written to create finding charts from FITS file data. It is designed to be used with the output of getimage and is available on any CfA CF Linux or Solaris machine. See also opchart, a Perl script written by Emilio Falco and Norm Grogin to create a label page for each set of four finding charts. Add /data/oiropt/bin to your search path to get getimage.

Before You Start

Set up the proper paths to access IDL and this program:
	setenv WIDL_STARTUP /data/astrodata/chart/xspam.ini
	alias widl "idl $WIDL_STARTUP"
	setenv IDL_DIR  /opt/rsi/idl  # latest IDL version
Type which idl and use the directory path above bin/idl. If you do not have IDL in your search path, try the path above, which we know works, or experiment with other versions found in /opt/rsi.
	setenv IDL_PATH \+$IDL_DIR/lib:\+$IDL_DIR/user_contrib
        [the plus sign will find routines in the subdirectories]

Example

  1. cd to the directory where your FITS files are to be located.
  2. Use getimage, redirecting the output to this directory as follows:
    	getimage -r [FITS directory]
    
  3. Type widl to start the IDL process.
  4. At the XSPAM prompt, type:
    	makeps,/fits,/invert,/label
    
    This invokes the makeps procedure to make postscript files with labels, color inverted, using FITS files as input. For each *.fits file in the directory, a *.ps postscript file will be created.
  5. Exit widl by typing "exit".
  6. Print the *.ps files on a postscript printer.

Remarks:

To make 4 charts per page, type:
	makeps4,/fits,/invert,/label
For every 4 FITS files in the directory, one *.ps file will be created and then psnup will be run to convert the postscript file to one with four images per page whose file name will start with "4". With makeps4, you can use a file for input by specifying list:
	makeps4,/fits,/invert,/label,/list

This will process only the fits files listed in a file called "fits.list", not all the files in the directory.

For four charts per page, print only the 4*.ps files.

To control the intensity levels in the plot, use makepsint:

	makepsint,/fits,/invert,/label,newdatamin=1000,newdatamax=5000

Color Map Error

Sometimes you will get the following error when running widl:

XSPAM 2.1> makeps,/fits,/invert,/label
% Attempt to subscript R with  is out of range.
% Execution halted at:  OVERLAYCT          36
  /home/jshaw/chart/pro/overlayct.pro
%                       MAKEPS             54 /home/jshaw/chart/pro/makeps.pro
%                       $MAIN$
XSPAM 2.1>

This generally indicates that your colormap has become corrupted. Try exiting color-intensive applications (like Netscape) and then start widl again. If that doesn't fix it, exit openwin and then try again.

Undefined procedure error

Note: makeps uses the IDL Astronomy Library routines which are now stored in subdirectories of /opt/idl/[IDL version]/user_contrib/astron/pro.

Your IDL_PATH environment variable should include \+$IDL_DIR/user_contrib/astron/pro (the plus sign will find routines in the subdirectories) to work correctly.


Last modified on December 30, 2011 by Jessica Mink