The gridprobe program interpolates/extracts the time series for a specified variable for a specified set of points from aGRIDDED3
input fileINFILE
, and writes the resulting time series as an M3IO file of typeCUSTOM3
or as columns to a (human-readable) ASCIIREPORT
-file with optional header, or both. Points to be extracted are specified in terms of Lat-Lon coordinates taken from an ASCIIPOINTS
file.Source code for program
gridprobe
is available under the GNU GPL License, Version 2, and can be downloaded from the CMAS web site as part of the I/O API distribution tar-ball from this page.
setenv INFILE <path name for input gridded file> setenv POINTS <path name for input points file> setenv REPORT <path name for output ASCII file> or "NONE" setenv OUTFILE <path name for output M3IO file> or "NONE" setenv HEADER <ASCII header on ${REPORT}? (Y/N) [N]> gridprobe [and answer the prompts]where INFILE is the logical name of the input data file, POINTS is the logical name of the ASCII points-file, and REPORT is the logical name of the report file to which the ASCII time series report is printed. INFILE must be of typeGRDDED3
. POINTS is a list-formatted (blank or comma delimited) ASCII file with up to 256 lines giving the latitude and longitude for the interpolation-points, with one point per line.
The program will prompt you for the starting and ending date and time and the time step for the report period, and the name of the variable to be reported. Default values for the time period are computed from the metadata in the INFILE header, and may be accepted by hitting theRETURN
key.The program will log both the input Lat-Lon coordinates and the corresponding grid-normal coordinates (i.e.,
1 + INT(X) = grid-column
and1 + INT(Y) = grid-row
):of the input points, and also write that information to theXgrid = ( X - XORIG ) / XCELL
Ygrid = ( Y - YORIG ) / YCELLREPORT
-file, if it is produced.If you want to run this program in batch mode (from a script), the recommended way to develop the script is to run the program once interactively noting the pattern of responses to prompts which generate the particular analysis you want. The pattern of responses then becomes either a command-input file which is redirected into the program in the script, or becomes a "here-document" fed into the execution.
To: Models-3/EDSS I/O API: The Help Pages