pandas.Index.fillna — pandas 1.0.1 documentation (original) (raw)

Index. fillna(self, value=None, downcast=None)[source]

Fill NA/NaN values with the specified value.

Parameters

valuescalar

Scalar value to use to fill holes (e.g. 0). This value cannot be a list-likes.

downcastdict, default is None

a dict of item->dtype of what to downcast if possible, or the string ‘infer’ which will try to downcast to an appropriate equal type (e.g. float64 to int64 if possible).

Returns

filledIndex