[ncl-talk] Problem with Binning MODIS data
Dennis Shea
shea at ucar.edu
Thu Jul 2 07:01:20 MDT 2015
http://www.ncl.ucar.edu/Document/Functions/Built-in/conform.shtml
http://www.ncl.ucar.edu/Document/Functions/Built-in/conform_dims.shtml
===
If x(20,406,270) and lat2d(406,270),lon2d(406,270)
do nf=0,nfil-1
print(nf+" "+fili(nf))
f = addfile(diri+fili(nf), "r")
; read data
lat2d = short2flt_hdf( f->Latitude )
lon2d = short2flt_hdf( f->Longitude)
x = short2flt_hdf( f->$vNam$ )
LAT = conform( x, lat2d, (/1,2/) )
LON = conform( x, lon2d, (/1,2/) )
delete( [/lat2d,lon2d/])
bin_sum(GBIN,GKNT,lon,lat \
,ndtooned(LON), ndtooned(LAT),ndtooned(x) )
delete( [/ x , LAT, LON ) ; size may change
end do
On Thu, Jul 2, 2015 at 3:20 AM, AJILESH PP <ajileshparolla at gmail.com> wrote:
> Dear all,
> I want to use this script (
> https://www.ncl.ucar.edu/Applications/Scripts/binning_1.ncl ) to bin and
> sum MODIS Level 2 data. While using the script I got an error on this line:
>
> bin_sum(GBIN,GKNT,lon,lat\ ,ndtooned(lon2d), ndtooned(lat2d),ndtooned(x) )
>
> and error says:
> fatal:bin_sum: z must be the same size as zlat and zlon.
> Lat2d and Lon2d sizes are 406*270 and Variable size is 20*406*270. I know
> this difference in size is the problem how to solve this? any help please
> Thanks in advance.
>
> _______________________________________________
> 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/20150702/d6cd334f/attachment.html
More information about the ncl-talk
mailing list