dask 2021.10.0

ParametersReturns
filled(a, fill_value=None)

This docstring was copied from numpy.ma.filled.

Some inconsistencies with the Dask version may exist.

If a is not a :None:None:`MaskedArray`, a itself is returned. If a is a :None:None:`MaskedArray` and :None:None:`fill_value` is None, :None:None:`fill_value` is set to a.fill_value .

Parameters

a : MaskedArray or array_like

An input object.

fill_value : array_like, optional.

Can be scalar or non-scalar. If non-scalar, the resulting filled array should be broadcastable over input array. Default is None.

Returns

a : ndarray

The filled array.

Return input as an array with masked data replaced by a fill value.

See Also

compressed

Examples

This example is valid syntax, but we were not able to check execution
>>> x = np.ma.array(np.arange(9).reshape(3, 3), mask=[[1, 0, 0],  # doctest: +SKIP
...  [1, 0, 0],
...  [0, 0, 0]])
... x.filled() # doctest: +SKIP array([[999999, 1, 2], [999999, 4, 5], [ 6, 7, 8]])
This example is valid syntax, but we were not able to check execution
>>> x.filled(fill_value=333)  # doctest: +SKIP
array([[333,   1,   2],
       [333,   4,   5],
       [  6,   7,   8]])
This example is valid syntax, but we were not able to check execution
>>> x.filled(fill_value=np.arange(3))  # doctest: +SKIP
array([[0, 1, 2],
       [0, 4, 5],
       [6, 7, 8]])
See :

Local connectivity graph

Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.

Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)

SVG is more flexible but power hungry; and does not scale well to 50 + nodes.

All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them


File: /dask/array/ma.py#19
type: <class 'function'>
Commit: