program fwhmed C This takes the known average fwhm for the frame (stored in tempfwhm) and C compared the fwhm of potential PSF stars. Anybody more than 15% of C the average number gets chucked. open(unit=1,file='tempfwhm',status='old') read(1,*) fwhm close(unit=1) sigave=fwhm/2.355 i1=0 i2=0 high=1.15*sigave alog=0.85*sigave open(unit=1,file='allradpsf',status='old') open(unit=2,file='tempxyed',status='new') 2 read(1,*,end=99) xc,yc,sig i1=i1+1 if(sig.gt.high) go to 2 if(sig.lt.alow) go to 2 C Ok, it survived. Now print it out write(2,*) xc,yc,sig i2=i2+1 C I've kept the sigs just so I can see the difference go to 2 99 close(unit=1) close(unit=2) write(6,100) i2,i1 100 format('FWHM filter kept',i5,' stars out of',i5) stop end