Unidata - To provide the data services, tools, and cyberinfrastructure leadership that advance Earth system science, enhance educational opportunities, and broaden participation. Unidata
         
  advanced  
 

[netcdfgroup] How to convert NetCDF data to T,Z,Y,X data

Hi list,
first of all, sorry for cross-posting.

I have some NetCDF data containing 4D variables having dimensions ordered as
Time, Lat, Lon,  Level.
I would like to "simply" re-arrange data to become having dimensions ordered
as Time, Level, Lat, Lon, as recommended (although not required) by
CF-Convention.
Is there an easy way to achieve this? (I'm using net-cdf java 2.2 APIs)

Basically I have a "test.nc" file with
attributes/variables/dimensions/more... and I would like to get a "
modified.nc" file where the "only difference" is having variables with
differently ordered dimensions (and data array respecting the new order).

Any suggestion or guidance line would be greatly appreciated.

Best Regards,
Daniele

-- 
-------------------------------------------------------
Eng. Daniele Romagnoli
Software Engineer

GeoSolutions S.A.S.
Via Carignoni 51
55041 Camaiore (LU)
Italy

phone: +39 0584983027
fax:     +39 0584983027
mob:   +39 328 0559267


http://www.geo-solutions.it

-------------------------------------------------------
 
 
  Contact Us     Site Map     Search     Terms and Conditions     Privacy Policy     Participation Policy
 
National Science Foundation (NSF) UCAR Community Programs   Unidata is a member of the UCAR Community Programs, is managed by the University Corporation for Atmospheric Research, and is sponsored by the National Science Foundation.
P.O. Box 3000     Boulder, CO 80307-3000 USA     Tel: 303-497-8643     Fax: 303-497-8690