pandas.api.typing.Rolling.apply
pandas 3.1.1 · Window operations · method
Run a callable over the units of the object, such as rows, columns, groups, or windows. The receiver controls which units it passes to the callable.
Call syntax
pd.api.typing.Rolling.apply(
func,
raw=False,
engine=None,
engine_kwargs=None,
args=None,
kwargs=None,
)Run the example
Edit the example and select Run Python to see the result.
Parameters
| Parameter | Requirement | Accepted values and behavior |
|---|---|---|
func |
Required Positional or keyword |
function Supply a supported operation name or a callable, depending on this API. |
raw |
Optional Positional or keyword Default False |
bool Choose whether the callable receives NumPy arrays rather than pandas objects where supported. |
engine |
Optional Positional or keyword Default None |
str Choose the implementation that performs the operation. |
engine_kwargs |
Optional Positional or keyword Default None |
dict Pass a dictionary of options to the selected engine. |
args |
Optional Positional or keyword Default None |
tuple |
kwargs |
Optional Positional or keyword Default None |
dict |
Returns
Series or DataFrame