#!/bin/sh # Create Long Island Sound topography grid at 3 arc second resolution # add 1 m to DEM data approximate conversion from # mean sea level to mean low water so it doesn't overwrite the # bathy values # # note: zcat below is the GZIP version that allows one to # zcat GZIPped files as well as UNIX compress zcat dem/*.xyz.gz | \ awk '{printf "%12.6f %12.6f %8.2f\n",$1,$2,$3+1}' > dem.xyz zcat lis_ngdc.dat.gz lis_appgeo.dat.gz lis_mgrim.dat.gz dem.xyz | \ blockmedian -R/-74/-71.2/40.5/41.5/ -I0.05m -V > li.median cat li.median | surface -R/-74/-71.2/40.5/41.5/ -I0.05m -Gli.grd -T0.35 -C0.2 -V grd2xyz li.grd | gzip -c > li.xyz.gz