Re: question about interpolation

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Fri Feb 19 2010 - 18:51:54 MST

The rcm2points function requires the data to be ordered
south-to-north.

The data from NCEP are N->S. Use NCl's syntax to reverse
the latitude [::-1]

Below, linint2_points is used. It is faster than rcm2points

load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"
begin
   nt = 0
   kl = 0

   fs1 = addfile("tmp.mon.mean.nc","r")
   var = fs1->tmp(nt,kl,::-1,:) ; make that latitudes S->N
   printVarSummary(var)

   yPts = (/20.5,20.5/)
   xPts = (/100.,100/)
   test = linint2_points_Wrap(var&lon, var&lat, var, False, xPts, yPts, 0)
   print(test)
end

Yang Gao wrote:
> To whom it may concern:
>
> I am trying to interpolate the lat/lon from NCEP(2.5by 2.5 degree data)
> to a certain location(let's say, 38.85N 77.04W), but it seemed it can
> not do using rcm2points. The attachment includes the script. It seemed
> that rcm2points can interpolate wrf grid for a certain location, but
> when I interpolate the NCEP data, it always shows up value like
> -9.96921e+36.
>
> Is there any requirement to interpolate using this function?
>
> I forgot attachment in last email, so I ask again.
>
> Thanks
>
> Yang
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Fri Feb 19 18:51:58 2010

This archive was generated by hypermail 2.1.8 : Tue Feb 23 2010 - 08:26:41 MST