cf.Field.filled

Field.filled(*args, **kwargs)[source]

Replace masked elements with a fill value.

Added in version 1.11.2.0.

Parameters:
fill_value: scalar, optional

The fill value. By default the fill returned by fill_value is used, or if this is not set then the netCDF default fill value for the data type is used (as defined by cf.default_netCDF_fillvals).

inplace: bool, optional

If True then do the operation in-place and return None.

Returns:
Field or None

The construct with filled data, or None if the operation was in-place.