
Interpolate at Height
interpolate_at_height.Rd
This function interpolates meteorological variablesat a specified height above ground.
Usage
interpolate_at_height(
var_s,
zg_s,
pa_s,
var_pl,
zg_pl,
pa_pl,
levels,
log_interp = FALSE,
nthreads = 1
)
Arguments
- var_s
variable [lon, lat, time] near the surface (K).
- zg_s
surface geopotential [lon, lat, time] (m^2/s^2).
- pa_s
surface pressure [lon, lat, lev, time] (hPa).
- var_pl
variable [lon, lat, lev, time] on pressure level (K).
- zg_pl
geopotential [lon, lat, lev, time] on pressure levels (m^2/s^2)
- pa_pl
pressure levels [lev] (hPa).
- levels
a numeric vector specifying heights (m) for interpolation, e.g., `c(500,6000)`.
- log_interp
Logical. If `TRUE`, performs interpolation in log-pressure space; otherwise, uses linear interpolation.
- nthreads
an integer specifying the number of threads to use for computation (OpenMP). Default is 1.