[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[THREDDS #MHJ-779129]: Fw: [support] NCEP/NCAR

Hi Muhammad,

Yeah, I should have expected that my explanation wouldn't be quite enough. The 
truth is that what you're trying to do--
while technically possible--is very tedious using OPeNDAP. We've developed 
another webapp for THREDDS called the
Netcdf Subset Service (NCSS) that makes it easy. Here [1] is an example. 
Unfortunately, the THREDDS server you're
downloading from doesn't have NCSS enabled, so we'll have to get by with 

1. If you look at the text box below the time variable, you'll see its metadata:

long_name: Time
delta_t: 0000-01-00 00:00:00
avg_period: 0000-01-00 00:00:00
prev_avg_period: 0000-00-01 00:00:00
standard_name: time
axis: T
units: hours since 1800-01-01 00:00:0.0
actual_range: 1297320.0, 1892664.0
_ChunkSize: 1

The key attribute here is "units: hours since 1800-01-01 00:00:0.0". That's how 
you interpret the values. The first
time is "1297320.0 hours since 1800-01-01" (this is a UDUNITS time [2], if 
you're curious). I assume you'll want to
convert this to a string time, and you can do so on this page [3]. "1297320.0 
hours since 1800-01-01" corresponds to

2. If you look at the declaration of "air" at the bottom of the page:

Float32 air[time = 816][level = 17][lat = 73][lon = 144];

you'll see that "air" is a 4-dimensional array with dimensions: time, level, 
lat, and lon. Each box corresponds to a
dimension and it is where you specify a range of indices for that dimension. 
So, it seems like you have the right idea
with your example sections except for time, which I discussed above.

3. When you submit a request, notice the URL that your browser goes to. It'll 
be something like:
At the end of the URL, you'll find the sections that you specified in the 
previous page. It looks like for each of the
requests you want to do, only the time section will vary. So, just figure out 
what time sections you need beforehand
(e.g. one for Jan 1985, one for Feb 1985, etc), and you should be able to 
construct the URLs of the the requests.
Then just put those URLs in a script (Bash, Python, whatever) and you can 
download the data in bulk.


[3] http://coastwatch.pfeg.noaa.gov/erddap/convert/time.html

Ticket Details
Ticket ID: MHJ-779129
Department: Support THREDDS
Priority: High
Status: Closed

NOTE: All email exchanges with Unidata User Support are recorded in the Unidata inquiry tracking system and then made publicly available through the web. If you do not want to have your interactions made available in this way, you must let us know in each email you send to us.