[ncl-talk] MODIS data problem

Dennis Shea shea at ucar.edu
Sun Mar 3 13:27:56 MST 2019


Hi Vanucia,

You are doing nothing "wrong."

The '*Golden Rule*' data processing is '*Know Your Data*'

A very useful function to explore a variable is * stat_dispersion
<http://www.ncl.ucar.edu/Document/Functions/Contributed/stat_dispersion.shtml>*

See attached:

%> ncl *MOD11A1.ncl_explore*

Not only will you get a feel for the data, the output can guide your
contour settings.

%> ncl *MOD11A1.ncl*

Good luck

*D*

On Sat, Mar 2, 2019 at 2:22 PM Vanúcia Schumacher <
vanucia-schumacher at hotmail.com> wrote:

> I'm trying to read MODIS data for daily mean temperature, but I think I'm
> doing something wrong because Maximo value is going up to 336 K. Any tips
> if I am reading correctly. Thanks
>
>
> SCRIPT:
>
> ;---HDF file name, also with HDFEOS suffix
>   fname_hdf = systemfunc("ls MOD11A1.A2*.hdf")
>   fname_he1 =
> "MOD11A1.A2015359.mosaic.006.2019043165512.psmcrpgscs_000501303977.LST_Day_1km.hdf"
>   fname_he2 = fname_he1 + ".he2"
>
> ;---Read data to be plotting as HDF lst_dayiable (not HE2).
>   a       = addfiles(fname_hdf,"r")
>               ListSetType(a,"join")
>   lst_day = short2flt(a[:]->LST_Day_1km)
>
> ;---Change the _FillValue, which is equal to 0.0 (NCL doesn't like 0.0 as
> a missing value)
>   lst_day at _FillValue = default_fillvalue(typeof(lst_day))
>
> ;---Read lat/lon grid as HDFEOS lst_day
>   agrid = addfile(fname_he2,"r")
>   lat   = agrid->GridLat_MODIS_Grid_Daily_1km_LST
>   lon   = agrid->GridLon_MODIS_Grid_Daily_1km_LST
>
> lst_day!0                = "time"
> lst_day!1                = "lat"
> lst_day!2                = "lon"
> lst_day at lat            = lat
> lst_day at lon           = lon
>
> Variable: lst_day
> Type: float
> Total Size: 6896628 bytes
>             1724157 values
> Number of Dimensions: 3
> Dimensions and sizes: [ncl_join | 3] x [YDim_MODIS_Grid_Daily_1km_LST |
> 1003] x [XDim_MODIS_Grid_Daily_1km_LST | 573]
> Coordinates:
> Number Of Attributes: 12
>   NCL_converted_from_type : ushort
>   hdf_name : LST_Day_1km
>   calibrated_nt : 5
>   add_offset_err :    0
>   scale_factor_err :    0
>   LST : LST data * scale_factor
>   Number_Type : uint16
>   units : K
>   long_name : Daily daytime 1km grid Land-surface Temperature
>   _FillValue_original : 0
>   _FillValue : 9.96921e+36
>   valid_range : ( 150, -0.02 )
> (0) Daily daytime 1km grid Land-surface Temperature (K) : min=270.34
> max=336.6
> (0) latitude (degrees_north) : min=-40.03057991847813
> max=-30.96683235691647
> (0) longitude (degrees_east) : min=-72.35461066157526
> max=-65.65836999384004
>
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190303/20ea5277/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: MOD11A1.ncl_explore
Type: application/octet-stream
Size: 2283 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190303/20ea5277/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: MOD11A1.ncl
Type: application/octet-stream
Size: 4667 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190303/20ea5277/attachment-0001.obj>


More information about the ncl-talk mailing list