I would like to know about a way to check the existence of coordinate
variable for a dimension in a variable.
I tried this way.
..............................
.............................
if(.not.isdefined(data&time))
print("Enter the file-variable representing time : ")
data&time = file1[:]->$systemfunc("read var; echo $var")$
end if
............................
.........................
My plan is to assign coordinate variable only if it is not already
assigned.
But it end up with an error message :
fatal:No coordinate variable exists for dimension (time) in variable (data)
Error is pointed at :
*if(.not.isdefined(data&time))*
The script is working if I remove the conditional statement.
How can I do it in a better way ?
-- *Gibies George, CSIR-RF, Climate and Global Modelling Division, Indian Institute of Tropical Meteorology, Dr. Homi Bhabha Road, NCL (P. O.), Pashan, Pune 411008, India.* *http://sites.google.com/site/gibiesge/* Think about the environment. Save paper; Save Trees. Please don't print this e-mail unless it is necessary.
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Feb 7 02:50:43 2011
This archive was generated by hypermail 2.1.8 : Fri Feb 11 2011 - 16:11:42 MST