# CL to magnify and combine a list of images # By Richard Elston 9/17/95 # procedure magcomb (inimage, offlist, inmask) string inimage {prompt="List of input images"} string offlist {prompt="Prefix name of output offset file"} string inmask {prompt="Prefix of mask image"} begin string inlist inlist=inimage imdel("m@"//inlist, yes) magnify ("@"//inlist, "m@"//inlist, 2., 1., x1=INDEF, x2=INDEF, dx=INDEF, y1=INDEF, y2=INDEF, dy=INDEF, interpolatio="nearest", boundary="constant", constant=0., fluxconserve=yes, logfile="STDOUT") imdel(inmask//"mag.pl", yes) magnify (inmask//".pl", inmask//"mag.pl", 2., 1., x1=INDEF, x2=INDEF, dx=INDEF, y1=INDEF, y2=INDEF, dy=INDEF, interpolatio="nearest", boundary="constant", constant=0., fluxconserve=no, logfile="STDOUT") hedit ("m@"//inlist, "BPM", inmask//"mag.pl", add=yes, delete=no, verify=no, show=yes, update=yes) del (offlist//".moff", yes) lintran (offlist//".aln", xs=2, ys=1, >offlist//".moff") imdel (offlist//".mag.imh", yes) imdel (offlist//".pl", yes) imcomb ("m@"//inlist, offlist//".mag.imh", plfile=offlist//".pl", sigma=offlist//".sig.imh", logfile="STDOUT", combine="average", reject="sigclip", project=no, outtype="real", offsets=offlist//".moff", masktype="badvalue", maskvalue=0., blank=0., scale="none", zero="med", weight="none", statsec="", expname="", lthreshold=INDEF, hthreshold=INDEF, nlow=1, nhigh=1, nkeep=1, mclip=yes, lsigma=3., hsigma=3., rdnoise="0.", gain="1.", snoise="0.", sigscale=0.1, pclip=-0.5, grow=0) imdel ("m@"//inlist, yes) display (offlist//".mag.imh",1) end