Re: decimalPlaces leading to loss of data

From: Rick Brownrigg <brownrig_at_nyahnyahspammersnyahnyah>
Date: Tue Nov 10 2009 - 09:27:36 MST

Hi Bridget,

Are you by chance running an earlier version of NCL? I noticed a
comment in the docs for "decimalPlaces" that
this function does not work correctly for NCL v. 5.0.0 and earlier, if
the data contain negative numbers. It does not spell out how "does
not work" manifests.

        http://www.ncl.ucar.edu/Document/Functions/Contributed/decimalPlaces.shtml

Rick

On Nov 9, 2009, at 4:18 PM, Bridget Thrasher wrote:

> I'm running a complete array (no missing values) through the
> decimalPlaces function and am getting an output array that contains
> missing values. Is this correct?
>
> data_all_f = doubletofloat(fdata->$var$)
> printVarSummary(data_all_f)
> print(num(ismissing(data_all_f)))
> printMinMax(data_all_f,True)
> data_all = decimalPlaces(data_all_f,2,True)
> printVarSummary(data_all)
> print(num(ismissing(data_all)))
> printMinMax(data_all,True)
>
>
> Variable: data_all_f
> Type: float
> Total Size: 116640000 bytes
> 29160000 values
> Number of Dimensions: 3
> Dimensions and sizes: [1800] x [90] x [180]
> Coordinates:
> Number Of Attributes: 1
> _FillValue : 1e+20
> (0) 0
> (0)
> (0) min=-73.7207 max=45.3083
>
>
> Variable: data_all
> Type: float
> Total Size: 116640000 bytes
> 29160000 values
> Number of Dimensions: 3
> Dimensions and sizes: [1800] x [90] x [180]
> Coordinates:
> Number Of Attributes: 1
> _FillValue : 1e+20
> (0) 2147
> (0)
> (0) min=-73.72 max=45.31
>
>
> --
> Bridget Thrasher, PhD
> Postdoctoral Researcher
> Climate Central
> www.climatecentral.org
>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Nov 10 09:26:53 2009

This archive was generated by hypermail 2.1.8 : Wed Nov 11 2009 - 12:48:56 MST