[ncl-talk] Error using code

Mike Victor mayuresh0987 at gmail.com
Wed Sep 2 23:59:54 MDT 2020


The below written code has some issue, when I run it, all the values of the
variable yPlot are set to _FillValue. Pls Help. Below is the link to the
netcdf file used in the code.
 olr.day.mean.nc
<https://drive.google.com/file/d/19Y0ExP6oDb_kT8wx-tqbPvUxGB7st7ma/view?usp=drive_web>





load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"


diri = "/home/mvaze123/OLRDATA"
fi = "/olr.day.mean.nc"
f = addfile(diri+fi,"r")
olr = f->olr
olr := olr(1675:16649,:,:) ;missing data till 1675th index, hence discarded
;printVarSummary(olr)
i = 0
j = 0
val = 0

ihp = 1
sigma = 1.0
nWgt = 49
fca = 1./121.
wgt = filwgts_lanczos(nWgt,ihp,fca,-999.,sigma)
yPlot = new((/14975,73,144/),"float")


do while (i .le. 72)

do while(j .le. 143)
val := wgt_runave(olr(:,i,j),wgt,0)
yPlot(:,i,j) = val
j= j+1
end do

i = i+1
end do
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.ucar.edu/pipermail/ncl-talk/attachments/20200903/b6eada20/attachment.html>


More information about the ncl-talk mailing list