[ncl-talk] non-alphanumeric variables in ncl-6.3.0

kblock karoline.block at uni-leipzig.de
Fri Nov 6 08:02:02 MST 2015


Dear all,

I have encountered a problem in ncl version 6.3.0 in reading 
non-alphanumeric variables from a net-cdf file (File format : netCDF4 
ZIP), which is not occuring in ncl version 6.0.0.
I have tested it using the same script and the same data on different 
servers with these two ncl version installed.

In the documentation it says you should read in like this:
x = f->$"ice cream+oreo-cookies...yummy!"$

But this only works in the older version!
For ncl 6.3.0 it is advisable to change the variable name before reading 
in the file (e.g. with cdo chname,oldvar,newvar ifile ofile).
Otherwise it seems that something similar as in asciiread will happen,  
that for the float and double type variables , the string 'nan' is read 
as a valid numerical value.

With ncl-6.3.0, the single-dimensioned float variable "/var0.4" was 
mostly read in as "-nan",
while with ncl-6.0.0 the same variable (now without the "/",even though 
it didn't matter for the reading in) was read in perfectly fine with the 
same command:
x = f->$"var0.4"$

After I changed the variable name to "var04" both versions work just fine!

I like to encourage the NCL Team to look at this and hopefully fix this 
problem!
Users are strongly advised to keep this in mind when reading data!

Cheers,
Karoline




More information about the ncl-talk mailing list