avg_drawdown_duration

qf_lib.common.utils.returns.avg_drawdown_duration.avg_drawdown_duration(prices_tms: QFSeries) float[source]

Finds the average duration of a drawdown for the given timeseries of prices.

Parameters:

prices_tms (QFSeries) – timeseries of prices

Returns:

average duration of a drawdown for the given timeseries of prices expressed in days

Return type:

float