pandas.api.extensions.ExtensionArray._pad_or_backfill
pandas 3.1.1 · Extensions · method
Implement directional missing-value filling for the extension array.
Call syntax
pd.api.extensions.ExtensionArray._pad_or_backfill(*, method, limit=None, limit_area=None, copy=True)Run the example
Edit the example and select Run Python to see the result.
Parameters
| Parameter | Requirement | Accepted values and behavior |
|---|---|---|
method |
Required Keyword only |
{'backfill', 'bfill', 'pad', 'ffill'} Choose the algorithm used to calculate, align, or fill the result. |
limit |
Optional Keyword only Default None |
int Set a maximum number of items affected by the operation. |
limit_area |
Optional Keyword only Default None |
{'inside', 'outside'} or None Restrict filling to gaps inside or outside valid observations. |
copy |
Optional Keyword only Default True |
bool Control whether data is copied where the API supports that choice. |
Returns
Same type as self