[ncl-talk] Unsigned byte in NCL 6.3.0

Wei Huang whuang at univ-wea.com
Mon Aug 10 09:42:33 MDT 2015


You need to read:
http://www.ncl.ucar.edu/Document/Manuals/Ref_Manual/NclDataTypes.shtml
to understand NCL data types, and how to convert between data types.

Wei Huang

-----Original Message-----
From: ncl-talk-bounces at ucar.edu [mailto:ncl-talk-bounces at ucar.edu] On Behalf Of Abhik Santra
Sent: Sunday, August 09, 2015 8:32 PM
To: ncl-talk
Subject: [ncl-talk] Unsigned byte in NCL 6.3.0

Hi

I am getting a problem while reading the file "EarthMap_2500x1250.nc", probably due to Unsigned byte type.
The variables in the input file are Unsigned type and the type has been changed in NCL 6.0.0 onwards.
This generates unusual image output for topo_9.ncl in NCL 6.3.0.
Although this can be readily solved by changing the version of NCL, but how can I do the same in the latest version of NCL?

The dataset is read as:
           Band1 = where(f->Band1.gt.255, 255, f->Band1)

and the File contains the data as:   
           byte Band1(lat, lon) ;
		Band1:long_name = "GDAL Band Number 1" ;
		Band1:_Unsigned = "true" ;
		Band1:valid_range = 0s, 255s ;
		Band1:_FillValue = 0b ;

Thanks in advance.

Regards,
Abhik

****************************************
Abhik Santra
Postdoctoral Research Fellow
Australian Bureau of Meteorology,
Melbourne, Australia
****************************************
_______________________________________________
ncl-talk mailing list
ncl-talk at ucar.edu
List instructions, subscriber options, unsubscribe:
https://urldefense.proofpoint.com/v2/url?u=http-3A__mailman.ucar.edu_mailman_listinfo_ncl-2Dtalk&d=BQICAg&c=qHNyRuJKHYeI-vwTnTfWXq4fkZpyjWUA1LcPL7eQSSQ&r=6RmpIe4P-G8omsHqYS85uBS-3JaNVk3lvOG-hmdOrr8&m=78zbJ3LrRT5H6GfMUNk8DlnMEXTW9uP7KnsCpyywD1s&s=SF4Ru23Hwii58oSAbD9aiVOoJJMqk1HDpki3trW30no&e= 


More information about the ncl-talk mailing list