- Dataset.hyoga.getvar(standard_name, infer=True, directions=None)#
Get a variable by conventional standard name.
str) – The variable’s “standard_name” attribute, which in principle should be set according to netCDF Climate and Forecast (CF) conventions (http://cfconventions.org/standard-names.html).
bool) – Try to infer missing variables from others present in the dataset. If one of the topographic variables (“bedrock_altitude”, “land_ice_thickness”, and “surface_altitude”) is requested and missing from the data, try to compute it from the other two. If a variable name starting with “magnitude_of” is requested and missing, try to compute it as the norm of its components.
directions (iterable) – Allowed direction keywords for computing vector magnitudes. Defaults to (“upward”, “downward”, “x”, “y”). Computing magnitudes on a sphere is not supported and thus longitude and latitude directions (“northward”, “southward”, “eastward”, “westward”) are not included by default.
DataArray) – The data array corresponding to that variable if a unique variable with that standard name has been found.