pandas.api.extensions.ExtensionArray._accumulate#
- ExtensionArray._accumulate(name, *, skipna=True, **kwargs)[source]#
Return an ExtensionArray performing an accumulation operation.
The underlying data type might change.
- Parameters:
- namestr
Name of the function, supported values are: - cummin - cummax - cumsum - cumprod
- skipnabool, default True
If True, skip NA values.
- **kwargs
Additional keyword arguments passed to the accumulation function. Currently, there is no supported kwarg.
- Returns:
- array
- Raises:
- NotImplementedErrorsubclass does not define accumulations
Examples
>>> arr = pd.array([1, 2, 3]) >>> arr._accumulate(name='cumsum') <IntegerArray> [1, 3, 6] Length: 3, dtype: Int64