IDL SCRIPTS ------------------------- The steps to analyse the data in IRAF are the following 1) Run the script routine_coo_mag_to_stats.pro This script will extract the relevant quantities from the IRAF .coo and .mag files and move them to a file with the extension _stats.txt in the chosen stats/ directory. (This is set as a keyword in the script). It will also fit a center to each frame (i.e. a center coordinate for the ShackHartman grid in each picture). Once these quantities have been extracted, the centers are piecemeal fit with 2) routine_center_drift.pro This will perfrom a linear fit to the center of the grid vs. time. The large jumps, assumed to be slews in the telescope are indicated as a file_number in the script. Once the new centers are calculated, the offsets of the centroids relative to the newly centered grids are obtained and put in the files offsets.txt. This is accomplished by running 3) routine_xy_offsets.pro There will be several output files. The first set of output files will have the extension _offsets.txt. They contain the value of the x offset, y offset, magnitude of the vector, angle of the vector, the bolometric magnitude and so on. The second set will have the extension sub_offsets.txt. These files have the average offset subtracted from each grid point to account for the distorted grid. Finally, the file Average_Offsets.txt will be output. This file contains the distortions of the grid from an ideal rectangle. The next step is to run 4) routine_cn_log_depth.pro