Re: Appropriate function?

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Wed Jul 24 2013 - 13:47:24 MDT

   x1(km,lat,lon) ==> x2(hPa,lat,lon)

How are we to know what 'km' is? If it one dimensional?

       km(:)

Always include a printVarSummary of the variable.

   printVarSummary(x1)
   printVarSummary(x1&km) ; if appropriate

===
The following is asuming 'km' is (:)

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

...
    printVarSummary(x1)
    print("x1: min="+min(x1)+" max="+max(x1))

    tdp = stdatmus_z2tdp(km)
    p = tdp(2,:)
    p!0 = "p"
    p@units = hPa"

    P = (/500,400,300,200,100/)
    P!0 = "P"
    P@units = "hPa"

===
    x2 = int2p_n_Wrap(p,x1,P,0,0)
    printVarSummary(x2)
    print("x2: min="+min(x2)+" max="+max(x2))

http://www.ncl.ucar.edu/Document/Functions/Contributed/int2p_n_Wrap.shtml

http://www.ncl.ucar.edu/Document/Functions/Built-in/stdatmus_z2tdp.shtml

On 7/23/13 1:41 PM, Marston Johnston wrote:
> Hi,
>
> I'm trying to find the appropriate NCL function to interpolate a 3D array
> with dimensions (km,lat,lon) to an array with (hPa,lat,lon) given the
> pressure array with dimensions (km,lat,lon) and the new pressure levels
> (500,400,300,200,100) hPa.
> I've been looking through the many interpolation functions in NCL but I
> cannot seem to find one that fits my needs. Is there such a function in NCL?
>
> Appreciate the help,
> /M
>
>
>
> _______________________________________________
> 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 Wed Jul 24 13:47:30 2013

This archive was generated by hypermail 2.1.8 : Thu Jul 25 2013 - 21:02:42 MDT