You can do the following:
v = short2flt(f1->V)
v@_FillValue = v_at_missing_value ; set FillValue to -32768
v@_FillValue = -999 ; set FillValue to -999
v_at_missing_value = v@_FillValue ; set missing_value to -999
Remember that NCL only recognizes the _FillValue attribute; it ignores
the missing_value attribute..
Adam
Song Feng wrote:
>
> Hi All:
>
> Suppose I have a multidimensional array (time, lev, lat, lon) with
> missing values '-32768'. How can I change the missing values to '-999'?
> The following is what I did, but it does not work.
>
> / v = short2flt(f1->V)/
> / v@_FillValue = -999/
> / printVarSummary(v)/
>
> The following is what I got:
>
> /Variable: v/
> /Type: float/
> /Total Size: 1014398976 bytes/
> / 253599744 values/
> /Number of Dimensions: 4/
> /Dimensions and sizes: [T | 1821] x [P | 17] x [Y | 64] x [X | 128]/
> /Coordinates: /
> / T: [-1247.5..572.5]/
> / P: [1000..10]/
> / Y: [-87.8638..87.8638]/
> / X: [ 0..357.1875]/
> /Number Of Attributes: 9/
> / valid_min : 5/
> / long_name : meridional wind/
> / units : M/S/
> / file_missing_value : -32768/
> / time_op : average/
> / _FillValue : -999/
> / missing_value : -32768/
>
>
> Best!
> Song Feng
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
-- -------------------------------------------------------------- Adam Phillips asphilli_at_ucar.edu National Center for Atmospheric Research tel: (303) 497-1726 ESSL/CGD/CAS fax: (303) 497-1333 P.O. Box 3000 Boulder, CO 80307-3000 http://www.cgd.ucar.edu/cas/asphilli _______________________________________________ ncl-talk mailing list List instructions, subscriber options, unsubscribe: http://mailman.ucar.edu/mailman/listinfo/ncl-talkReceived on Wed Nov 05 2008 - 10:08:03 MST
This archive was generated by hypermail 2.2.0 : Fri Nov 07 2008 - 13:41:15 MST