xarray.Dataset.pr.fill_all_na

Dataset.pr.fill_all_na(dim: DimOrDimsT, value=0) Dataset

Fill NA values only where all values along the specified dimension(s) are NA.

Example: if you have a Dataset with dimensions time and positions, filling it along time will only fill those values where all time-points are NA in each DataArray.

Parameters:
dim: str or list of str

Dimension(s) to evaluate. NA values are only filled if all values along these dimension(s) are also NA.

value: optional

Fill value to use. Default: 0.

Returns:
filledxr.Dataset