[ncl-talk] Missing value set to -nan?
David Brown
dbrown at ucar.edu
Tue Jan 20 12:50:29 MST 2015
Hi Liz,
Use the procedure, replace_ieeenan.
(https://www.ncl.ucar.edu/Document/Functions/Built-in/replace_ieeenan.shtml)
-dave
On Tue, Jan 20, 2015 at 12:27 PM, Elizabeth Burakowski
<burakows at ucar.edu> wrote:
> I'm running into an issue with missing values set to '-nan'.
>
> dir= "/glade/p/work/burakows/nohrsc/mNOHRSC_mslt_200811_200904/"
> fils= systemfunc("cd "+dir+" ; ls avg*.nc")
> a=addfiles(dir+fils(1:4)+".nc","r")
> ListSetType(a,"join")
> b=a[:]->z
>
> printVarSummary(b) ; note that b at _FillValue is set to -nan & actual range
> (0, 653)
> print(min(b)) ; minimum value is showing up as -nan instead of 0
> print(max(b)) ; maximum value is showing up as -nan instead of
> 653
>
> I tried resetting the _FillValue to -9999:
>
> b at _FillValue = -9999
> printVarSummary(b) ; now b at _FillValue is -9999, range is
>
> Any ideas on how to get rid of the -nan?
>
> Thanks,
>
> Liz.
>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
More information about the ncl-talk
mailing list