<div dir="ltr"><div><div><div><div>Hi,<br></div>After interpolating the irregular grid to regular, the output plot reflects the missing values for most of the region. I attached here an output figure.<br></div>I would appreciate any help and suggestions to fix this issue. <br><br></div>Thanks<br></div>Dz<br><br><br>begin<br><br><br><br>  iz = addfile("<a href="http://landsea2_wrf.nc">landsea2_wrf.nc</a>","r")<br>  lat2d = iz->lat<br>  lon2d = iz->lon<br> mas=iz->mask<br><br>  c = addfile("<a href="http://era-down_1989_apr-sep_22z.nc">era-down_1989_apr-sep_22z.nc</a>","r")<br>  t2    = cds->p<br>  <br>  t2!1="lon2d"<br>  t2!2="lat2d"<br>  t2@lon2d = lon2d<br>  t2@lat2d = lat2d<br>printVarSummary(t2)<br>aavg= t2(time|:,lat2d|:,lon2d|:)<br>printVarSummary(aavg)<br>print(aavg(0,:,0))<br>printMinMax(aavg,0)<br>printMinMax(lat2d,0)<br>printMinMax(lon2d,0)<br>;******************************************************<br>;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;<br>f1    = addfile("/import/h/marchforecast/mar1982-2010/<a href="http://simpleWunit.2005031212.nc">simpleWunit.2005031212.nc</a>", "r")   ; note the "s" of addfile<br>T1    = f1->precSum                ; read T from all files<br>printVarSummary (T1)<br>latnew=f1->lat_0<br>lonnew=f1->lon_0<br>;;;;;;Interpolation Step;;;;;;;;;;;;;;;;;;;;;;;;;;;;;<br>;printVarSummary(T)<br>;printVarSummary(aavg)<br>;print(aavg)<br>printVarSummary(aavg)<br>newsst = rcm2rgrid_Wrap(lat2d,lon2d,aavg,latnew,lonnew,1)<br>printMinMax(newsst,0)<br>printVarSummary(newsst)<br>print(newsst)<br><br><br>  system("/bin/rm -f <a href="http://simple.nc">simple.nc</a>")   ; remove any pre-existing file<br>       ncdf = addfile("<a href="http://simple.nc">simple.nc</a>" ,"c")  ; open output netCDF file<br><br>    ;===================================================================<br>    ; create global attributes of the file (optional)<br>    ;===================================================================<br>       fAtt               = True            ; assign file attributes<br>       fAtt@title         = "NCL Simple Approach to netCDF Creation"<br>       fAtt@source_file   =  "<a href="http://original-file.nc">original-file.nc</a>"<br>       fAtt@Conventions   = "None"<br>       fAtt@creation_date = systemfunc ("date")<br>       fileattdef( ncdf, fAtt )            ; copy file attributes<br><br>    ;===================================================================<br>    ; make time an UNLIMITED dimension; recommended  for most applications<br>    ;===================================================================<br>       filedimdef(ncdf,"time",-1,True)<br><br>    ;===================================================================<br>    ; output variables directly; NCL will call appropriate functions<br>    ; to write the meta data associated with each variable<br>    ;===================================================================<br>ncdf->newsst  = newsst<br><br>end<br> <br></div>