On Feb 8, 2008 9:47 AM, Steven Weiss &lt;<a href="mailto:sweiss@iafrica.com">sweiss@iafrica.com</a>&gt; wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">






<div bgcolor="#ffffff">
<div><font face="Arial" size="2">Hi Arlindo,</font></div>
<div><font face="Arial" size="2"></font>&nbsp;</div>
<div><font face="Arial" size="2">I downloaded the latest <a href="http://lats4d.gs" target="_blank">lats4d.gs</a> and am getting
errors. See reults below.</font></div>
<div><font face="Arial" size="2"></font></div></div></blockquote><div><br>Hmm. I got this to work:<br><br>&nbsp;lats4d -i <a href="http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z">http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z</a> -o test -lat -35 -30 -lon 17.5 30 -v -format grads_grib&nbsp; -vars htsgwsfc<br>
<br>BTW, I am using <br><br>lats4d: Version 1.9.4 of 28 Nov 2007<br><br>while you seem to be using a much earlier version:<br><br><font face="Arial" size="2"><span class="nfakPe">lats4d</span>: Version 1.7 of 10 May 2006</font><br>
<br>I am attaching my latest. I&#39;ll be posting this on <a href="http://sf.net">sf.net</a> shortly.<br><br>&nbsp; Let me know whether it works.<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arlindo<br><br><br><br><br><br><br>&nbsp;</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div bgcolor="#ffffff"><div>&nbsp;</div>
<div><font face="Arial" size="2">Regards</font></div>
<div><font face="Arial" size="2">Steven</font></div>
<div><font face="Arial" size="2"></font>&nbsp;</div>
<div><font face="Arial" size="2">1ga-&gt; lats4d -i <a href="http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/n3_18z" target="_blank">http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/n3_18z</a>
-o test -vars htsgwsfs -lat -35 -30 -lon 17.5 30 -v -format
grads_grib<br>lats4d: Version 1.7 of 10 May 2006<br>No hardcopy metafile
open<br>All files closed; all defined objects released<br>All GrADS attributes
have been reinitialized<br>Scanning self-describing file:&nbsp; <a href="http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z" target="_blank">http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z</a><br>
Found
11 data variables in SDF file.<br>Found displayable variable dirpwsfc with 0
levels in SDF file.<br>Found displayable variable dirswsfc with 0 levels in SDF
file.<br>Found displayable variable htsgwsfc with 0 levels in SDF file.<br>Found
displayable variable perpwsfc with 0 levels in SDF file.<br>Found displayable
variable perswsfc with 0 levels in SDF file.<br>Found displayable variable
ugrdsfc with 0 levels in SDF file.<br>Found displayable variable vgrdsfc with 0
levels in SDF file.<br>Found displayable variable wdirsfc with 0 levels in SDF
file.<br>Found displayable variable windsfc with 0 levels in SDF
file.</font></div>
<div><font face="Arial" size="2">Found displayable variable wvdirsfc with 0 levels
in SDF file.<br>Found displayable variable wvpersfc with 0 levels in SDF
file.<br>lats4d: Data file is <br>File 1 : WAVE_nww3 Global wave model fcst from
18Z06feb2008, downloaded Feb 06 23:11 UTC<br>&nbsp; Descriptor: <a href="http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z" target="_blank">http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z</a><br>
&nbsp;
Binary: <a href="http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z" target="_blank">http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z</a><br>&nbsp;
Type = Gridded<br>&nbsp; Xsize = 288&nbsp; Ysize = 157&nbsp; Zsize = 1&nbsp;
Tsize = 61<br>&nbsp; Number of Variables = 11<br>&nbsp;&nbsp;&nbsp; dirpwsfc 0
-999 ** surface primary wave direction [deg] <br>&nbsp;&nbsp;&nbsp; dirswsfc 0
-999 ** surface secondary wave direction [deg] <br>&nbsp;&nbsp;&nbsp; htsgwsfc 0
-999 ** surface sig height of wind waves and swell [m] <br>&nbsp;&nbsp;&nbsp;
perpwsfc 0 -999 ** surface primary wave mean period [s] <br>&nbsp;&nbsp;&nbsp;
perswsfc 0 -999 ** surface secondary wave mean period [s] <br>&nbsp;&nbsp;&nbsp;
ugrdsfc 0 -999 ** surface u wind [m/s] <br>&nbsp;&nbsp;&nbsp; vgrdsfc 0 -999 **
surface v wind [m/s] <br>&nbsp;&nbsp;&nbsp; wdirsfc 0 -999 ** surface wind
direction [deg] <br>&nbsp;&nbsp;&nbsp; windsfc 0 -999 ** surface wind speed
[m/s] <br>&nbsp;&nbsp;&nbsp; wvdirsfc 0 -999 ** surface direction of wind waves
[deg] <br>&nbsp;&nbsp;&nbsp; wvpersfc 0 -999 ** surface mean period of wind
waves [s] </font></div>
<div>&nbsp;</div>
<div><font face="Arial" size="2">lats4d: Dimension environment file same as data
file</font></div>
<div><font face="Arial" size="2">lats4d: creating LATS PARAMETER TABLE file
.grads.lats.table<br>LATS warning (lats_parmtab): Closing the previously opened
Parameter Table: .grads.lats.table<br>lats4d: time range: 18Z06FEB2008
18Z06FEB2008 by 1, delta t: 3 hourly<br>lats4d: vertical levels:&nbsp;
0<br>lats4d: invalid plev 0 for GRIB output<br>lats4d: using HYBRID level number
for vertical coordinate<br>lats4d: latitudinal&nbsp; range: -35 -30<br>lats4d:
longitudinal range: 17.5 30<br>Failure reading SDF data.&nbsp; #1<br>Data
Request Error:&nbsp; Error for variable &#39;dirpwsfc&#39;<br>&nbsp; Error ocurred at
column 1<br>DISPLAY error:&nbsp; Invalid expression <br>&nbsp; Expression =
dirpwsfc<br>lats4d: error creating grads_grib file test.grb<br></font>Original
Message ----- </div>
<blockquote style="border-left: 2px solid rgb(0, 0, 0); padding-right: 0px; padding-left: 5px; margin-left: 5px; margin-right: 0px;">
  <div style="background: rgb(228, 228, 228) none repeat scroll 0% 50%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; font-family: arial; font-style: normal; font-variant: normal; font-weight: normal; font-size: 10pt; line-height: normal; font-size-adjust: none; font-stretch: normal;">
<b>From:</b>
  <a title="dasilva@ALUM.MIT.EDU" href="mailto:dasilva@ALUM.MIT.EDU" target="_blank">Arlindo da
  Silva</a> </div>
  <div style="font-family: arial; font-style: normal; font-variant: normal; font-weight: normal; font-size: 10pt; line-height: normal; font-size-adjust: none; font-stretch: normal;"><b>To:</b> <a title="GRADSUSR@LIST.CINECA.IT" href="mailto:GRADSUSR@LIST.CINECA.IT" target="_blank">GRADSUSR@LIST.CINECA.IT</a> </div>

  <div style="font-family: arial; font-style: normal; font-variant: normal; font-weight: normal; font-size: 10pt; line-height: normal; font-size-adjust: none; font-stretch: normal;"><b>Sent:</b> Friday, February 08, 2008 3:56
  PM</div>
  <div style="font-family: arial; font-style: normal; font-variant: normal; font-weight: normal; font-size: 10pt; line-height: normal; font-size-adjust: none; font-stretch: normal;"><b>Subject:</b> Re: GradsDODS</div><div>
<div></div><div class="Wj3C7c">
  <div><br></div>
  <div class="gmail_quote">On Feb 8, 2008 1:44 AM, Steven Weiss &lt;<a href="mailto:sweiss@iafrica.com" target="_blank">sweiss@iafrica.com</a>&gt; wrote:<br>
  <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;">
    <div bgcolor="#ffffff">
    <div><font face="Arial" size="2">Hi,</font></div>
    <div><font face="Arial" size="2">I am downloading a grib file and processing it
    through my script. It all works great. I have since discovered that I can
    avoid the 34mb download by using gradsdods and opening up a server url e.g.
    <a href="http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z" target="_blank">http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z</a></font></div>
    <div><font face="Arial" size="2"></font>&nbsp;</div>
    <div><font face="Arial" size="2">I can run my script over this successfully
    however it is painfully slow. I am retrieving all the variables over 180hr
    for a specified lat/lon grid point.</font></div>
    <div><font face="Arial" size="2"></font></div></div></blockquote>
  <div>&nbsp;</div>
  <div>&nbsp;</div>
  <div>Grib2 has great compression capabilities at the expense of speed: it
  takes time to decompress the files. While switching to GRIB2 may have
  decresead data&nbsp;storage&nbsp;requirementments&nbsp;for the data producers
  and download time for the people getting the actual files, it certainly caused
  a degradation&nbsp;of the OPeNDAP services for sites serving the grib-2 files
  directly.</div>
  <div>&nbsp;</div>
  <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;">
    <div bgcolor="#ffffff">
    <div><span></span>&nbsp;</div>
    <div><font face="Arial" size="2">A little bit of investigation tells me that I
    should be downloading a subset of the data to my local drive i.e. a lat/lon
    range and running my script&nbsp;over that instead.</font></div>
    <div><font face="Arial" size="2"></font>&nbsp;</div>
    <div><font face="Arial" size="2">How can I do this?&nbsp;Some examples would be
    useful.</font></div>
    <div><font face="Arial" size="2"></font>&nbsp;</div></div></blockquote>
  <div>&nbsp;</div>
  <div>If you want to do this over&nbsp;OPeNDAP you can use lats4d (see recent
  posting for the latest script). Here is an example for creating a subset of
  the data:</div>
  <div>&nbsp;</div>
  <div>lats4d -i&nbsp;<a href="http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z" target="_blank">http://nomad5.ncep.noaa.gov:9090/dods/waves/nww3/nww320080206/nww3_18z</a>&nbsp;&nbsp;-o
  myfile -vars <b>ugrdsfc </b>vg<b>rdsfc -lat 20 60 -lon -100 20
  -v</b></div><b></b></div>
  <div class="gmail_quote">&nbsp;</div>
  <div class="gmail_quote">If you omit -vars, you get all variables, if you omit
  the -lat/-lon you get the whole domain; you can also specify -time/-levs if
  you would like to subset along those dimensions. &nbsp;In grads v1.9, by
  default this will produce a netcdf file called <a href="http://myfile.nc" target="_blank">myfile.nc</a>; use &quot;-format grads_grib&quot; to get a
  grib-1 file, &quot;-format stream&quot; to get a flat binary, &quot;-format sequential&quot; for a
  f77 sequential file. At this point you can only specify -format
  sream/sequential with grads v2.</div>
  <div class="gmail_quote">&nbsp;</div>
  <div class="gmail_quote">Another point, you can use this command inside
  gradsdods, or from the unix command line with the lats4d sh(1) script (this
  also be done under windows if using sh.exe or tcsh.exe). The command line
  wrapper is useful for putting lats4d based fetches on a crontab.</div>
  <div class="gmail_quote">&nbsp;</div>
  <div class="gmail_quote">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Arlindo</div>
  <div class="gmail_quote">&nbsp;</div>
  <div class="gmail_quote">&nbsp;</div>
  <div class="gmail_quote">&nbsp;</div>
  <div class="gmail_quote">&nbsp;</div>
  <div class="gmail_quote">
  <div><br></div>
  <div>&nbsp;</div>
  <div>&nbsp;</div>
  <div>&nbsp;</div>
  <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;">
    <div bgcolor="#ffffff">
    <div><span></span></div>
    <div><font face="Arial" size="2">Regards</font></div>
    <div><font face="Arial" size="2">Steven
  </font></div></div></blockquote></div><br><br clear="all"><br>-- <br>Arlindo da
  Silva<br><a href="mailto:dasilva@alum.mit.edu" target="_blank">dasilva@alum.mit.edu</a>
</div></div></blockquote></div>
</blockquote></div><br><br clear="all"><br>-- <br>Arlindo da Silva<br><a href="mailto:dasilva@alum.mit.edu">dasilva@alum.mit.edu</a>