[Thread Prev][Thread Next][Index]

Re: [ferret_users] Adding NC files.




Hi,

I think it would be better to use a tool like NCO (netcdf operators http://nco.sourceforge.net/  ) to fix these files. Just cut out the first or last record as appropriate with "ncks" so that each file contains unique time information. The history attribute that gets created is a good record of what you have done too. If the time dimension is the record dimension then it's easy to create a descriptor file joining up all the individual files avoiding duplication.

http://ferret.pmel.noaa.gov/Ferret/documentation/users-guide/converting-to-netcdf/CREATING-A-MULTI-FILE-NETCDF-DATA-SET#_VPID_367

I use the second tool, make_des, but I presume nc2mc works fine too.

Russ


On 07/04/15 06:40, Ansley Manke wrote:
Hi,
You can use SAVE/APPEND to create a big file with all the data - if they are on the same grid. The timesteps need to be defined using the same time encoding.

I'm not sure what is going on when there are 32 days in a monthly file. You can give the time range on the SAVE command, so if what's happening is that for example, the January file contains January 1 through February 1, you can write out just the dates you want.

So if your grids are compatible, this might look something like:

yes? use name_1.nc
yes? save/file=output_name.nc/clobber/t=1-jan-2001:31-dec-2001 temperature

yes? cancel data/all
yes? use name_2.nc
yes? save/file=output_name.nc/append/t=1-feb-2001:28-feb-2001 temperature

and so on.


On 4/4/2015 2:01 AM, Satyam Srivastava wrote:
Hi ferret Users,

I would like to add 12 monthly data ncdf files to make one single file for a year and the monthly data looks like ::

    1> ./ADE253FA893926BCC8C8D7AFB00247CF_ferret_listing.nc  (default)
 name     title                             I         J         K         L         M         N
 TEMPERATURE
          potential temperature (degc)     1:2001    1:1093    1:10      1:31


like this there are 11 more files for a year so could you please help me with that i have tried to do that but i am unable to do so.

There is one more problem that in some files the data is for 32 days please guide me the process so that i can make one single file for a year.

I have tried the REPEAT command but that did not worked.

Regards,
Satyam Srivastava.



[Thread Prev][Thread Next][Index]
Contact Us
Dept of Commerce / NOAA / OAR / PMEL / Ferret

Privacy Policy | Disclaimer | Accessibility Statement