dome = 1 if ( dome ) then begin ;{ window,xsize=339,ysize=678 window,2,xsize=600,ysize=400 endif ;} close,1 & close,13 pmn = 15000. & pmx = 30000. xmn = 0. & xmx = 339. lfilenm = 'cmp_biaslist' filenm=' ' filenmb=' ' close,13 & openr,13,lfilenm imgB=intarr(339,339) imgC=intarr(339,339) while ( not eof(13) ) do begin ;{ readf,13,filenm img = readfits(filenm,hdr,silent=1) expt = float(sxpar (hdr , 'SHUTTER')) lcvrv = fix(sxpar (hdr , 'LCVR-V')) lcvrt = float(sxpar (hdr , 'LCVR-T')) byteorder,img img = float(img) img = (img lt 0. ) * ( img + 32768. + 32768.) + (img ge 0.)*(img) readf,13,filenmb bias = readfits(filenmb,hdr,silent=1) expt_bias = float(sxpar (hdr , 'SHUTTER')) lcvrv_bias = fix(sxpar (hdr , 'LCVR-V')) lcvrt_bias = float(sxpar (hdr , 'LCVR-T')) byteorder,bias bias = float(bias) bias = (bias lt 0. ) * ( bias + 32768. + 32768.) + (bias ge 0.)*(bias) img = img - bias cavg = total ( img (100:2033-100 , 1017 ) ) / (2034. - 200. ) print,filenm,' ',expt, lcvrv , cavg opal = strmid(filenm,0,2) if ( opal eq '5B' ) then begin ;{ imgB = rebin(img, 339,339) wset,0 & & erase & tv,bytscl(imgB,min=22000,max=24000) imgC (*,*) = 0. testB = imgB(50:250,339/2) testC = testB testF = testB endif if ( opal eq '5C' ) then begin ;{ imgC = rebin(img, 339,339) wset,0 & tv,bytscl(imgC,min=2200,max=2500),0, 339 ;;;; Ratio should be: ( 7.76e-7 / 8.00e-8 ) @POISE w.l. testC = imgC(50:250,339/2) * ( 7.76e-7 / 8.00e-8 ) coeff = poly_fit(testB,testC,1,yfit,yband,sigma,corrm) print,coeff(0), coeff(1) , sigma testF = testB *coeff(1) + coeff(0) wset,2 plot,testF , testC , /ynoz endif ;;wset,2 ;;plot,[xmn,xmx],[pmn,pmx],/nodata,xstyle=1,ystyle=1 ;;oplot,testB, thick=2 ;;oplot,testC,linestyle=2,thick=2 endwhile ;} close,13 print, ( 51.0543 - 52.6925 ) / ( 51.0543 + 52.6925 ) print, ( 85.5148 - 74.1184 ) / ( 85.5148 + 74.1184 ) print, ( 56.3780 - 64.3668 ) / ( 56.3780 + 64.3668 ) print, ( 59.8298 - 58.1361 ) / ( 59.8298 + 58.1361 ) print,(( 51.0543 - 52.6925 ) / ( 51.0543 + 52.6925 ) + $ ( 85.5148 - 74.1184 ) / ( 85.5148 + 74.1184 ) + $ ( 56.3780 - 64.3668 ) / ( 56.3780 + 64.3668 ) + $ ( 59.8298 - 58.1361 ) / ( 59.8298 + 58.1361 ) ) *0.25 print,'Positive so _bias is just a bit better!' end