--- a/meanProf
+++ b/meanProf
@@ -2,15 +2,16 @@
#======================================================================
# M E A N P R O F
# doc: Fri Feb 22 08:40:18 2008
-# dlm: Fri Feb 22 18:02:40 2008
+# dlm: Wed Mar 16 07:02:38 2016
# (c) 2008 A.M. Thurnherr
-# uE-Info: 232 0 NIL 0 0 72 74 2 4 NIL ofnI
+# uE-Info: 14 49 NIL 0 0 72 0 2 4 NIL ofnI
#======================================================================
# extract time-averaged mean profile from ADCP data
# HISTORY:
# Feb 22, 2008: - created from [listBins]
+# Mar 16, 2016: - adapted to new Getopt library
# Soundspeed Correction:
# - applied as described in the RDI coord-trans manual
@@ -18,7 +19,8 @@
# => - same simple correction for all velocity components
# - simple correction for cell depths
-require "getopts.pl";
+use Getopt::Std;
+
$0 =~ m{(.*/)[^/]+};
require "$1RDI_BB_Read.pl";
require "$1RDI_Coords.pl";
@@ -33,7 +35,7 @@
"[-M)agnetic <declination>] " .
"[-D)epth <depth>] " .
"<RDI file>\n")
- unless (&Getopts("4bd:D:M:p:r:QS:") && @ARGV == 1);
+ unless (&getopts("4bd:D:M:p:r:QS:") && @ARGV == 1);
die("$0: -4 and -d are mutually exclusive\n")
if ($opt_4 && defined($opt_d));