File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -3526,6 +3526,8 @@ def set_fill_value(self, value=None):
3526
3526
def filled (self , fill_value = None ):
3527
3527
"""
3528
3528
Return a copy of self, with masked values filled with a given value.
3529
+ **However**, if there are no masked values to fill, self will be
3530
+ returned instead as an ndarray.
3529
3531
3530
3532
Parameters
3531
3533
----------
@@ -3537,7 +3539,9 @@ def filled(self, fill_value=None):
3537
3539
-------
3538
3540
filled_array : ndarray
3539
3541
A copy of ``self`` with invalid entries replaced by *fill_value*
3540
- (be it the function argument or the attribute of ``self``.
3542
+ (be it the function argument or the attribute of ``self``), or
3543
+ ``self`` itself as an ndarray if there are no invalid entries to
3544
+ be replaced.
3541
3545
3542
3546
Notes
3543
3547
-----
You can’t perform that action at this time.
0 commit comments