Reddy, You can also do this easily with Ferret. Have a look at the topics under "append" in the index to the Ferret Users Guide http://ferret.pmel.noaa.gov/Ferret/documentation/users-guide/index-1/index/ The example in the documentation which shows appending to a netCDF file has the input files in ascii format. Your example would be much easier, yes? use file1.nc yes? save/clobber/file=outfile.nc uvar yes? cancel data file1 yes? use file2.nc yes? save/append/file=outfile.nc vvar yes? cancel data file2 yes? use file3.nc yes? save/append/file=outfile.nc uvar yes? cancel data file3 yes? use file4.nc yes? save/append/file=outfile.nc vvar yes? cancel data file4 ... This assumes that the files have time defined consistently, that is they have time axes with time in the same units and with the same time origin. (CDO also has requirements on the time information in the files, so it can make sense of the time steps.) If the grids in the files do not have time axes, or if they are not defined consistently, you can use Ferret to define a common time axis and to define variables regridded to that time axis, and then write those to the output file. The Notes in the documentation on SAVE talks about these in more detail, http://ferret.pmel.noaa.gov/Ferret/documentation/users-guide/commands-reference/SAVE On 10/2/2013 1:09 PM, Fabrício Zimmerer
Murta wrote:
|