haw2gnu v3.2.3¶
Mercurial revision 5770:c90c3015e72d | 2026-05-22
Description¶
haw2gnu reformats mooring observations from the Hawaii Institute format to the MATROOS standard.
Usage¶
haw2gnu [OPTIONS] file
Options¶
Option |
Description |
|---|---|
|
Show help and exit. |
|
Start date for extraction (format: |
|
End date for extraction (format: |
|
Duplicate the input file for safety (creates a |
|
Duplicate the input file with depths multiplied by 1000 (creates a |
|
Output format: |
|
Output rootname (without extension). If not provided, the input filename is used with the appropriate extension ( |
Examples¶
Basic Conversion to obs Format¶
Convert a Hawaii Institute file to obs format (default):
haw2gnu input.dat
Output: input.obs
Convert to matroos Format¶
Convert a Hawaii Institute file to matroos format:
haw2gnu -f matroos input.dat
Output: input.slv
Extract Data for a Specific Period¶
Extract observations between January 2000 and December 2010:
haw2gnu -start 01/2000 -end 12/2010 input.dat
Duplicate Input File for Safety¶
Create a backup of the input file while processing:
haw2gnu -d input.dat
Output: input.duplicated.dat (backup) + input.obs (converted file).
Duplicate Input File with Depths ×1000¶
Create a copy of the input file with depths multiplied by 1000:
haw2gnu -t input.dat
Output: input.truncated.dat (depths ×1000) + input.obs (converted file).
Custom Output Rootname¶
Specify a custom output filename:
haw2gnu -o output_root input.dat
Output: output_root.obs
Combine Options¶
Extract data for a specific period, duplicate the input file, and convert to matroos format:
haw2gnu -start 06/2005 -end 06/2015 -d -f matroos -o custom_output input.dat
Output:
input.duplicated.dat(backup)custom_output.slv(converted file)
Environment Variables¶
None.
Notes¶
Date Format:
Dates must be provided in
MM/YYYYformat (e.g.,01/2000for January 2000).The
-endoption requires the-startoption to be defined.
Input File:
Only one input file can be processed at a time.
The input file must be in Hawaii Institute format.
Output Files:
If
-ois not specified, the output filename is derived from the input filename:.obsextension forobsformat (default)..slvextension formatroosformat.
Duplication Options:
-dcreates a backup of the input file with.duplicated.datextension.-tcreates a modified copy of the input file with depths multiplied by 1000 and.truncated.datextension.
Deprecated Options:
-c(time function tests) is deprecated and no longer supported.
See Also¶
MATROOS Standard (for output format details)
Hawaii Institute Mooring Data (for input format details)