[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
20020122: gempak ltg gridding
- Subject: 20020122: gempak ltg gridding
- Date: Thu, 24 Jan 2002 11:25:25 -0700
Brian,
Unfortunately, you cannot enter a time range for gdattim
in GDDIAG. You can make your shell script loop through the times,
or create a program to do it internally. You probably will have to be careful
in gddiag not to overwrite a grid that you are using as input.
The GDSTAT program almost does what you want already. It computes
the avarage, standard deviation, and number of observations
for a time series. The total of a field ODEN would be
MUL(AVGODEN,NUMODEN). Or, the program could be modified to save the TOT
total that is used for the average.
Steve Chiswell
Unidata User Support
>From: Brian Colle <address@hidden>
>Organization: UCAR/Unidata
>Keywords: 200201230006.g0N06Rx14260
>
>Hi,
>
>A while back you helped me the lightning counting program below. It works
>great for plotting, but now I want to add up all the strikes within a grid
>for a certain time period. I am trying to do this using the gddiag
>program:
>
>#!/bin/csh -f
>#
>gddiag << xxx
>GDFILE = june.grd
>GDOUTF = june.grd
>GFUNC = add(odentot^000601/0000,oden)
>GDATTIM = ALL
>GLEVEL = 0
>GVCORD = none
>GRDNAM = odentot
>GPACK =
>run
>
>exit
>xxx
>exit
>
>but I am having problems with the GDATTIM. It appears that GDATTIM
>doesn't recognize ALL, and 000601/0005-000630/2355 does not seem to work
>for me either. If I set GDATTIM=000601/0005 it works ok. Before I
>write a program to loop through all the 5 minute times in the file, I just
>wanted to make sure I wasn't missing something subtle with GDATTIM?
>
>Thanks for your time.
>
>Brian
>
>On Wed, 24 Oct 2001, Unidata Support wrote:
>
>>
>> Brian,
>>
>> I have created a program called GDOBSCNT that will find the
>> number of observations within a specified radius of each grid
>> point and store the grid as parameter ODEN@0%none for each
>> time specified from the input surface file.
>>
>> You can download the tarfile from:
>> http://www.unidata.ucar.edu/packages/gempak/contrib/gdobscnt.tar.Z
>>
>> In your GEMPAK 5.6 $NAWIPS directory, unpack the tarfile with:
>>
>> zcat gdobscnt.tar.Z | tar xvf -
>>
>> Then build and install with:
>>
>> cd $NAWIPS/unidata/programs/gdobscnt
>> make clean
>> make all
>> make install
>> make clean
>>
>>
>> To use the program, you should first create your grid file with your
>> required grid spacing using GDCFIL.
>>
>> The program uses 4 parameters. SFFILE, DATTIM, GDFILE, RADIUS.
>> SFFILE is your input surface (NLDN) file. GDFILE is the
>> file for the grids to be stored. DATTIM is the times
>> (a list, range, single, or all) from the surface file
>> to process. RADIUS is the range, in meters, from the
>> each grid point that stations will be counted.
>>
>> The result is a grid called ODEN for each time specified
>> by DATTIM.
>>
>> For example, using today's 1630Z NLDN file (which contains
>> nldn bins at 5 minute intervals from 1630Z to 1655Z), and a grid
>> file I have already created called test.grd specifying a 50KM
>> radius (50000m):
>>
>> % gdobscnt
>> SFFILE Surface data file nldn|011024/1630
>> DATTIM Date/time all
>> GDFILE Grid file test.grd
>> RADIUS Radius (in meters) to search 50000
>> Parameters requested: SFFILE,DATTIM,GDFILE,RADIUS.
>> GEMPAK-GDOBSCNT>r
>> Processing 011024/1630
>> Processing 011024/1635
>> Processing 011024/1640
>> Processing 011024/1645
>> Processing 011024/1650
>> Processing 011024/1655
>> Parameters requested: SFFILE,DATTIM,GDFILE,RADIUS.
>> GEMPAK-GDOBSCNT>e
>>
>> I can then plot the data, with grid point values and contous in GDPLOT2
>> with:
>> GDFILE = test.grd
>> GDATTIM = 1630-1655
>> GLEVEL = 0
>> GVCORD = none
>> PANEL = 0
>> SKIP = 0
>> SCALE = 0
>> GDPFUN = ODEN
>> TYPE = cm
>> CONTUR = 0
>> CINT = 0
>> LINE = 3
>> FINT =
>> FLINE =
>> HILO =
>> HLSYM =
>> CLRBAR = 1
>> WIND =
>> REFVEC =
>> TITLE = 1
>> TEXT = 1
>> CLEAR = y
>> GAREA = 34.0;-95.2;43.7;-79.2
>> PROJ = LCC/25.0;-90.0;25.0
>> MAP = 1
>> LATLON = 0
>> DEVICE = XW
>> STNPLT =
>> SATFIL =
>> RADFIL =
>> LUTFIL =
>> STREAM =
>> POSN = 0
>> COLORS = 5
>> MARKER = 0
>> GRDLBL = 0
>> FILTER = 0
>> GEMPAK-GDPLOT2>r
>> Creating process: xw for queue 12551
>> [TG 0] 1630-1655
>> Number of times = 6
>> 1 011024/1630
>> 2 011024/1635
>> 3 011024/1640
>> 4 011024/1645
>> 5 011024/1650
>> 6 011024/1655
>> <etc...>
>>
>> The TYPE=cm in gdplot2 will plot both the contours of the data as well as
>> the data values at the grid point locations (marker=0).
>>
>> Let me know if you have questions/problems/etc.
>>
>> Steve Chiswell
>> Unidata User Support
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> >From: Unidata Support <address@hidden>
>> >Organization: UCAR/Unidata
>>
>> >
>> >Brian,
>> >
>> >The ltgmap program was the same program as sfmap. It just allowed a
>> >greater number of times/observations. In GEMPAK 5.6, I increased
>> >the number of times/observations in sfmap so that a separate ltgmap program
>> >wasn't needed.
>> >
>> >The lat/lon locations are the station locations (each lightning strike
>> >is treated as a "ship" report).
>> >
>> >I can create a program in the next few days that will read the surface file
>
>> >and create the grid of "reports within a DELTA radius".
>> >
>> >Steve Chiswell
>> >Unidata User SUpport
>> >
>> >
>> >
>> >
>> >
>> >>From: Brian Colle <address@hidden>
>> >>Organization: UCAR/Unidata
>> >>Keywords: 200110222134.f9MLY8102451
>> >
>> >>
>> >>Steve,
>> >>
>> >>>
>> >>> Brian,
>> >>>
>> >>> At this point in time, there is nothing within GEMPAK
>> >>> to make this type of computation as you require.
>> >>>
>> >>> I would be possible to write a program to accumulate the number
>> >>> of strikes within a given radius of a grid point.
>> >>>
>> >>
>> >>In order to write another program I need to know how to open and
>> >>read the ltg sfc file to extract the lat/longs for each lightning strike,
>> >>assuming that they are stored that way. Just to clarify, is there a gempak
>> >>fortran subroutine that will read the file and extract this information?
>> >>For example, I used to use ltgmap, which plotted the individual lightning
>> >>strikes. I was hoping that I could take advantage of the way ltgmap reads
>> >>in the data, but only use the lat/long info. I notice that the latest
>> >>version of gempak doesn't even use ltgmap anymore?
>> >>
>> >>> The other limitation you would have is that a 3km grid is going
>> >>> to be a very large grid if you are attempting to cover the
>> >>> entire country with a single grid. At present time, the default
>> >>> maximum number of grid points in a file is 400,000.
>> >>> A 4km national grid is approximately 1,200,000 points.
>> >>>
>> >>> If you are doing a regional (or series of regional) grids
>> >>> then that won't be a problem.
>> >>>
>> >>
>> >>Yes, I only want the regional NE US.
>> >>
>> >>Thanks again,
>> >>
>> >>Brian
>> >>
>> >>> >
>> >>> >Hi,
>> >>> >
>> >>> >I have some gempak lightning data (surface files of sgnl strength) that
> I
>> >>> >want to interpolate to a uniformly spaced 3-km gempak grid such that ea
> ch
>> >>> >grid point has the number of nearby strikes. With this gridded file I c
> an
>> >>> >then contour the number density up in gempak.
>> >>> >
>> >>> >Do you have any ideas or sample code how I can do this interpolation
>> >>> >of lightning data within gempak or interfacing gempak with f77?
>> >>> >
>> >>> >I appologize in advance for the loaded question, but I am looking
>> >>> >for ideas at this point.
>> >>> >
>> >>> >Thanks for your time...
>> >>> >
>> >>> >Brian
>> >>> >____________________________________________________________
>> >>> >Prof. Brian Colle INTERNET: address@hidden
>> >>> >(631)632-3174
>> >>> >Institute for Terrestrial and Planetary Atmospheres
>> >>> >Marine Sciences Research Center
>> >>> >State University of New York at Stony Brook
>> >>> >Stony Brook, NY 11794-5000
>> >>> >
>> >>>
>> >>> ************************************************************************
> ***
>> > *
>> >>> Unidata User Support UCAR Unidata Pro
> gra
>> > m
>> >>> (303)497-8644 P.O. Box
> 300
>> > 0
>> >>> address@hidden Boulder, CO 8
> 030
>> > 7
>> >>> ------------------------------------------------------------------------
> ---
>> > -
>> >>> Unidata WWW Service http://www.unidata.ucar.edu/
>
>> >
>> >>> ************************************************************************
> ***
>> > *
>> >>>
>> >>
>> >
>> >
>>
>> ****************************************************************************
>> Unidata User Support UCAR Unidata Program
>> (303)497-8644 P.O. Box 3000
>> address@hidden Boulder, CO 80307
>> ----------------------------------------------------------------------------
>> Unidata WWW Service http://www.unidata.ucar.edu/
>> ****************************************************************************
>>
>