NCL Website header
NCL Home > Documentation > Functions > Meteorology

hyi2hyo_Wrap

Interpolates from data on one set of hybrid levels to another set of hybrid levels and preserves metadata.

Prototype

load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"  ; This library is automatically loaded
                                                             ; from NCL V6.2.0 onward.
                                                             ; No need for user to explicitly load.

	function hyi2hyo_Wrap (
		p0     [1] : numeric,  
		hyai   [*] : numeric,  
		hybi   [*] : numeric,  
		ps         : numeric,  
		xi         : numeric,  
		hyao   [*] : numeric,  
		hybo   [*] : numeric,  
		intflg [1] : integer   
	)

	return_val  :  numeric

Arguments

p0

A scalar value equal to the surface reference pressure. Must have the same units as ps.

hyai

A one-dimensional array containing the hybrid coefficients A associated with xi. Must be ordered top-to-bottom. Must be unitless.

hybi

A one-dimensional array containing the hybrid coefficients B associated with xi. Must be ordered top-to-bottom. Must be unitless.

ps

A multi-dimensional array containing pressures. Must be at least two dimensions and one dimension smaller than xi. The level dimension is ordered top-to-bottom. Must have the same units as p0.

xi

A multi-dimensional array containing the variable to be interpolated. The three rightmost dimensions must be level, lat, and lon. The level dimension is ordered top-to-bottom.

hyao

A one-dimensional array containing the hybrid coefficients A associated with the return_val. Must be ordered top-to-bottom. Must be unitless.

hybo

A one-dimensional array containing the hybrid coefficients B associated with the return_val. Must be ordered top-to-bottom. Must be unitless.

intflg

A scalar integer which specifies the type of extrapolation to be used. A value of 0 will cause all values outside of input pressure range to to be set to xi's missing value (or 1e20 if none). A value of 1 will set output values to the closest input pressure level.

Description

This function is identical to hyi2hyo, except the return value will have metadata added based on metadata attached to xi. See the hyi2hyo page for full documentation and examples.