geocat.comp.interpolation._vertical_remap_extrap#
- geocat.comp.interpolation._vertical_remap_extrap(new_levels, lev_dim, data, output, pressure, ps, variable, t_bot, phi_sfc)#
A helper function to call the appropriate extrapolation function based on the user’s inputs.
- Parameters:
new_levels (array-like) – The desired pressure levels for extrapolation in Pascals.
lev_dim (
str
) – The name of the vertical dimension.data (
xarray.DataArray
) – The data to extrapolateoutput (
xarray.DataArray
) – An array to hold the output datapressure (
xarray.DataArray
) – The pressure at the lowest level of the model. Must be in the same units aslev
andps
ps (
xarray.DataArray
) – An array of surface pressures. Must be in the same units aslev
andp_sfc
variable (
str
, optional) – String representing what variable is extrapolated below surface level. Temperature extrapolation = “temperature”. Geopotential height extrapolation = “geopotential”. All other variables = “other”. If “other”, the value ofdata
at the lowest model level will be used as the below ground fill value. Required if extrapolate is True.t_bot (
xarray.DataArray
) – Temperature at the lowest (bottom) level of the model.phi_sfc – The geopotential at the lowest level of the model.
- Returns:
output (
xarray.DataArray
) – A DataArray containing the data after extrapolation.