;Program to make plotting arrays temp = lonarr(1) av = lonarr(10,10) vr = lonarr(10,10) tlong = lonarr(1) avg = lonarr(8) var = lonarr(8) read, 'Insert the x coord of the pixel (use an integer).',x read, 'Insert the y coord of the pixel (use an integer).',y x = long(x) y = long(y) ; ;Get the pixel element from the arrays exp = 1 FOR j = 0,7 DO BEGIN favg = 'ns' + string(exp) + '.avg' favg = STRCOMPRESS(favg,/REMOVE_ALL) fvar = 'ns' + string(exp) + '.var' fvar = STRCOMPRESS(fvar,/REMOVE_ALL) openr,1,favg for k = 0,9 do begin s = x + LONG(k) for l = 0,9 do begin t = y + LONG(l) z = 4*(256L*t + s) POINT_LUN,1, z readu,1,temp av(k,l) = temp endfor endfor close,1 openr,1,fvar for k = 0,9 do begin s = x + LONG(k) for l = 0,9 do begin t = y + LONG(l) z = 4*(256L*t + s) POINT_LUN,1, z readu,1,tlong vr(k,l) = tlong endfor endfor close,1 ;print,tfloat,temp,j avg(j) = LONG(total(av)/100) var(j) = LONG(total(vr)/100) exp = 2*exp ENDFOR openw,1,'calib.pic' writeu,1,avg writeu,1,var close,1 plot,avg,var end