pro summars, day, fname, out ; a procedure to collapse the 3D information from a ; scanned source in november '05 to a 1D spectrum ; EXAMPLE: If the file is ~/nov05/33/pipe/mars.3001 ; IDL> summars,'33','mars.3001',m1 ; the output spectrum will be called m1.sp and wavenumber scale ; will be called m1.wn ; EXAMPLE PLOT OF THE OUTPUT: ; IDL> plot,m1.wn,m1.sp,ps=10,xs=1 ; If the procedure is run multiple times to sum a number ; of these files: ; IDL> plot,m1.wn,m1.sp+m2.sp+m3.sp+...,ps=10,xs=1 dir='~/nov05/'+day+'/pipe/' rdpipe,dir+fname,mars mars1=total(mars.im,3) mars2=total(mars1,2) out=create_struct('sp',mars2,$ 'wn',mars.wn) end