[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[netCDF #OZU-387092]: [Question] Data.
- Subject: [netCDF #OZU-387092]: [Question] Data.
- Date: Wed, 05 Dec 2012 13:52:53 -0700
Hi,
> This is Seungwoo Jason Chang who is a pH.D student of University of
> Florida. I downloaded the NetCDF data in this website
> (http://geoport-dev.whoi.edu/thredds/ncss/grid/prism4/monthly/dataset.html),
> but I can't find the any directions about the data. For example, in my
> downloaded file, time variable varies like 13194
> 13225 13253 13284 13314 13345 13375 13406 13437 13467 ... . Is there
> any direction to figure out the meaning of these values or standard?
>
> I asked Gibson who is the creator of these data
> (http://geoport-dev.whoi.edu/thredds/prism4.html?dataset=prism4/monthly),
> but he said the data was converted in your website, so he has no idea
> about it.
>
> Appreciate if you could explain to me this or give some contacts I can
> ask.
According to the "Gridded Dataset Description", which is a link you can click
on,
the time coordinate is defined as follows:
<axis name="time" shape="1403" type="float" axisType="Time">
<attribute name="units" value="days since 1858-11-17 00:00:00"/>
<attribute name="_ChunkSize" type="int" value="1"/>
<attribute name="_CoordinateAxisType" value="Time"/>
<values>
13194.0 13225.0 13253.0 13284.0 13314.0 13345.0 13375.0 13406.0 13437.0
13467.0 13498.0 13528.0 13559.0
13590.0 13619.0 13650.0 13680.0 13711.0 13741.0 13772.0 ...
so the units are days since 1858-11-17 00:00:00". You can convert this to a
date/time using various libraries, but here is a way using the netCDF utilities
ncgen and ncdump.
First create a netCDF CDL file, "days.cdl" for example, which is just an ASCII
file that could look like this:
netcdf days {
dimensions:
time = UNLIMITED ; // (20 currently)
variables:
float time(time) ;
time:units = "days since 1858-11-17 00:00:00" ;
data:
time = 13194, 13225, 13253, 13284, 13314, 13345, 13375, 13406, 13437, 13467,
13498, 13528, 13559, 13590, 13619, 13650, 13680, 13711, 13741, 13772 ;
}
Then use ncgen to make a binary netCDF file, "days.nc" out of days.cdl, like
this:
$ ncgen -b days.cdl
Finally, dump that out with ncdump using the "-t" option to translate times
to a human-readable form, like this:
$ ncdump -t days.nc
for which the output is:
netcdf days {
dimensions:
time = UNLIMITED ; // (20 currently)
variables:
float time(time) ;
time:units = "days since 1858-11-17 00:00:00" ;
data:
time = "1895-01-01", "1895-02-01", "1895-03-01", "1895-04-01", "1895-05-01",
"1895-06-01", "1895-07-01", "1895-08-01", "1895-09-01", "1895-10-01",
"1895-11-01", "1895-12-01", "1896-01-01", "1896-02-01", "1896-03-01",
"1896-04-01", "1896-05-01", "1896-06-01", "1896-07-01", "1896-08-01" ;
}
So it looks like the times are just the first day of consecutive months ...
--Russ
Russ Rew UCAR Unidata Program
address@hidden http://www.unidata.ucar.edu
Ticket Details
===================
Ticket ID: OZU-387092
Department: Support netCDF
Priority: Low
Status: Closed