pandas.api.typing.Resampler.mean

pandas 3.1.1 · Resampling · method

Calculate the arithmetic mean of values in the selection, group or window.

Call syntax

pd.api.typing.Resampler.mean(numeric_only=False)

Run the example

Edit the example and select Run Python to see the result.

Parameters

ParameterRequirementAccepted values and behavior
numeric_only Optional
Positional or keyword
Default False
bool

Restrict the calculation to columns pandas considers numeric where applicable.

Returns

DataFrame or Series