;+ ; NAME: ; QUICKDARK ; PURPOSE: ; Look at last few days of dark data for any changes. ; The plot shows image totals of the standard daily darks. ; The dashed line shows the level as of the end of June, 1998 ; plus the SAA images - a lot of them, since we do Med rate then. ; Keep your eye on the off-scale points! ; CATEGORY: ; CALLING SEQUENCE: ; main program ; INPUTS: ; OPTIONAL (KEYWORD) INPUT PARAMETERS: ; OUTPUTS: ; COMMON BLOCKS: ; SIDE EFFECTS: ; makes a plot in the current window ; RESTRICTIONS: ; MODIFICATION HISTORY: ; 2-jul-98, written (HSH) ; 18-jul-98, made into a procedure (HSH) ; 13-aug-98, changed hard paths to environment paths (DA) ; 22-aug-98, changed path to $DIR_SITE_NEWDATA* (HSH) ; 22-Jul-99, Make plot work during CCD bakeout (BNH) ; 14-Aug-99, Reduce plot ranges; added qstop (HSH) ; 28-Sep-99, Changed findfile to find_file to handle long strings. (PGS) ; 11-jan-99, explicitely sorted by time the output from find_file, y2k (PGS) ;- pro quickdark, side=side, qstop=qstop if n_elements(side) eq 0 then side = 512 wdef,0,side ;infil = findfile('/yd3/reformat/sfr*') ;infil = findfile('$DIR_GEN_NEWDATA/sfr*') ;infil = findfile('$DIR_SITE_NEWDATA*/sfr*') infil_t = find_file('$DIR_SITE_NEWDATA/sfr*') infil = infil_t(sort(file2time(infil_t))) ;y2k (pgs) tstart = anytim2ints(!stime,offset=-3600.*28*24) rd_roadmap,infil,rm tt = tim2dset(rm,tstart) rm1 = rm ss = where(gt_filta(rm1) eq 1 and gt_filtb(rm1) eq 3 and $ gt_dpe(rm1) eq 13 and $ gt_percentd(rm1) eq 100 and gt_expmode(rm1) eq 1) rd_xda,infil,ss,index,data tt = tim2dset(index,tstart) index=index(tt:*) data = data(*,*,tt:*) tots = reform(total(total(sxt_decomp(data),1),1))/(256.^2)/4 yr = [28, 40] ;yr = [min([28, tots]), max([36, tots])] ; For CCD bakeout (BNH) utplot,index,tots,psym=-2,ytit='DN/sec/HRpix',yr=yr,tit='Dark for last month' fmt_timer,index,t1,t2 outplot,[t1,t2],[31.0894,31.0894],lines=1 saa = where(saa_in(index)) evt_grid,index(saa) timestamp if keyword_set(qstop) then stop ;print,stdev(tots,mean),mean end