punpy.digital_effects_table.measurement_function_utils.MeasurementFunctionUtils.calculate_unc_missingdim

punpy.digital_effects_table.measurement_function_utils.MeasurementFunctionUtils.calculate_unc_missingdim#

MeasurementFunctionUtils.calculate_unc_missingdim(form, ds, var, ydims=None, sizes_dict=None, expand=False)[source]#

Function to extract uncertainties of given form on given variable from the given datasets when there are missing dimensions. With missing dimension, we here mean a dimension that is present in the measurand, but not in the input quantity being considered.

Parameters:
  • form (str) – name or type of uncertainty component

  • ds (xarray.dataset) – given dataset

  • var (str) – given variable

  • ydims (list(str)) – list of dimensions of the measurand, in correct order.

  • sizes_dict (dict) – Dictionary with sizes of each of the dimensions of the measurand.

  • expand (bool) – boolean to indicate whether the input quantities should be expanded/broadcasted to the shape of the measurand.

Returns:

uncertainty values for the given variable in the given dataset. returns None if uncertainty component is not present in dataset.

Return type:

np.ndarray