pandas.core.window.expanding.Expanding.quantile

Expanding.quantile(quantile, interpolation='linear', **kwargs)[source]

Calculate the expanding quantile.

Parameters
quantilefloat

Quantile to compute. 0 <= quantile <= 1.

interpolation{‘linear’, ‘lower’, ‘higher’, ‘midpoint’, ‘nearest’}

This optional parameter specifies the interpolation method to use, when the desired quantile lies between two data points i and j:

  • linear: i + (j - i) * fraction, where fraction is the fractional part of the index surrounded by i and j.

  • lower: i.

  • higher: j.

  • nearest: i or j whichever is nearest.

  • midpoint: (i + j) / 2.

**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.

See also

pandas.Series.expanding

Calling expanding with Series data.

pandas.DataFrame.expanding

Calling expanding with DataFrames.

pandas.Series.quantile

Aggregating quantile for Series.

pandas.DataFrame.quantile

Aggregating quantile for DataFrame.