Dear NCL users,
I am joining two files (one for ascending and the other for descending AIRS data) but am struggling to get the file time attributes into the new file. The descending file contains daily temperature data at 1:30am while ascending contains daily Temperatre at 13:00hrs. The times are in UTC. Could someone help. Below is my script that I am using
;load files and read dimensions
system("/bin/rm -f AIRST_2012f.nc")
a = addfile("AIRST_2012fdes.nc","w")
print(a)
AIRSTdes = a->AIRSTdes
b = addfile("AIRST_2012fasc.nc","w")
print(b)
AIRSTasc = b->AIRSTasc
;define dimensions
desdsize = dimsizes(AIRSTdes)
desdsize = (/desdsize(0),desdsize(1),desdsize(2),desdsize(3)/)
ascdsize = dimsizes(AIRSTasc)
ascdsize = (/ascdsize(0),ascdsize(1),ascdsize(2),ascdsize(3)/)
;define total variable
;create new variable
AIRST = new((/desdsize(0)+ascdsize(0),desdsize(1),desdsize(2),desdsize(3)/),float)
AIRST(::2,:,:,:) = AIRSTdes
AIRST(1::2,:,:,:) = AIRSTasc
AIRST!0 = "time"
AIRST&time = time
;write output file
system("/bin/rm -f AIRST_2012f.nc")
fout=addfile("AIRST_2012f.nc","c")
fout@title="AIRST_2012f"
fout->AIRST = AIRST
printVarSummary(AIRST)
One of the files (AIRST_2012fasc) attributes which are common to both are:
title : AIRST_2012fasc
dimensions:
time = 31
level = 11
LAT = 3
LON = 47
variables:
float AIRSTasc ( time, level, LAT, LON )
_FillValue : -9999
hdf_name : Temperature_A
float time ( time )
_FillValue : 9.96921e+36
units : Days since 0UTC 1 January 2000
float level ( level )
units : hPa
float LAT ( LAT )
units : degrees_south
float LON ( LON )
units : degrees_east
Thank you
Ditiro
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Oct 1 23:30:07 2013
This archive was generated by hypermail 2.1.8 : Fri Oct 04 2013 - 16:45:17 MDT