#!/bin/csh

setenv Q /home/atmos/q/research

cd $Q/ppt/obs/katz

compile create_tblfil

set yr = 97
set mn = 08
set dy = 01
while( $dy <= 31 )
 if (-e $Q/nicppt/katz/tmp/usa-dlyprcp-19$yr$mn$dy) then
  echo $yr$mn$dy

  if (-e new.tbl) rm new.tbl
  ~bemcdona/tr.help $Q/nicppt/katz/tmp/usa-dlyprcp-19$yr$mn$dy
  create_tblfil katz.tblfl $Q/nicppt/katz/tmp/usa-dlyprcp-19$yr$mn$dy
  sort new.tbl -o katz.tblfl

 endif
 @ dy = $dy + 1
 if ( $dy < 10 ) set dy = "0"$dy

end
