xarray.Dataset.notnull¶
-
Dataset.
notnull
(keep_attrs=None)¶ Test each value in the array for whether it is not a missing value.
- Returns
notnull – Same type and shape as object, but the dtype of the data is bool.
- Return type
See also
Examples
>>> array = xr.DataArray([1, np.nan, 3], dims="x") >>> array <xarray.DataArray (x: 3)> array([ 1., nan, 3.]) Dimensions without coordinates: x >>> array.notnull() <xarray.DataArray (x: 3)> array([ True, False, True]) Dimensions without coordinates: x