pandas.core.window.expanding.Expanding.sem¶
- Expanding.sem(ddof=1, *args, **kwargs)[source]¶
Calculate the expanding standard error of mean.
- Parameters
- ddofint, default 1
Delta Degrees of Freedom. The divisor used in calculations is
N - ddof, whereNrepresents the number of elements.- *args
For NumPy compatibility and will not have an effect on the result.
- **kwargs
For NumPy compatibility and will not have an effect on the result.
- Returns
- Series or DataFrame
Return type is the same as the original object with
np.float64dtype.
See also
pandas.Series.expandingCalling expanding with Series data.
pandas.DataFrame.expandingCalling expanding with DataFrames.
pandas.Series.semAggregating sem for Series.
pandas.DataFrame.semAggregating sem for DataFrame.
Notes
A minimum of one period is required for the calculation.
Examples
>>> s = pd.Series([0, 1, 2, 3])
>>> s.expanding().sem() 0 NaN 1 0.707107 2 0.707107 3 0.745356 dtype: float64