Average Drawdown

PortfolioOptimisers.AverageDrawdown — Type
struct AverageDrawdown{__T_settings, __T_w} <: RiskMeasure

Measures the Average Drawdown, the mean depth of the uncompounded drawdown over the sample.

The drawdown series is the one of absolute_drawdown_vec: the cumulative return is a sum of the returns, and its running peak starts at $c_0 = 0$. RelativeAverageDrawdown takes the same mean of the compounded drawdown series.

Mathematical definition

\[\begin{align} \mathrm{ADD}(\boldsymbol{x}) &= -\frac{1}{T} \sum_{t=1}^{T} d_t\,. \end{align}\]

Where:

  • $\mathrm{ADD}(\boldsymbol{x})$: Average drawdown.
  • $\boldsymbol{x}$: Portfolio returns vector $T \times 1$.
  • $d_t \leq 0$: Absolute drawdown at period $t$. absolute_drawdown_vec states the series.
  • $T$: Number of observations.

With observation weights, the measure takes the weighted mean:

\[\begin{align} \mathrm{ADD}(\boldsymbol{x}) &= -\frac{1}{W_{T}} \sum_{t=1}^{T} w_{t} d_t\,. \end{align}\]

Where:

  • $w_{t}$: Observation weight of observation $t$.
  • $W_{T} = \sum_{t=1}^{T} w_{t}$: Total observation weight.

The drawdown series reads the full return path, so an observation with zero weight still moves every later drawdown. A path that never falls below its running peak has an Average Drawdown of zero. The measure is the limit of ConditionalDrawdownatRisk as alpha rises to one, because the tail then holds the whole sample.

[200] defines the measure without weights. The weighted mean is the library's extension of that work.

Algorithm

  1. Compute the drawdown series with absolute_drawdown_vec.
  2. Resolve the observation weights with checked_observation_weights.
  3. Return average_drawdown of the series and the weights.

Fields

  • settings: Risk measure settings.
  • w: Optional observation weights vector observations × 1, or a concrete subtype of DynamicAbstractWeights. If nothing, the computation is unweighted.

Constructors

AverageDrawdown(;    settings::RiskMeasureSettings = RiskMeasureSettings(),    w::Option{<:ObsWeights} = nothing) -> AverageDrawdown

Keywords correspond to the struct's fields.

Validation

Propagated parameters

factory passes its arguments on to these @fprop fields:

Observation weight parameters

obs_weights_view indexes these fields to the selected observations:

Functor

(r::AverageDrawdown)(x::VecNum)

Computes the Average Drawdown of a portfolio returns vector x.

Arguments

  • x::VecNum: Portfolio returns vector.

Examples

julia> AverageDrawdown()AverageDrawdown  settings ┼ RiskMeasureSettings           │   scale ┼ Float64: 1.0           │      ub ┼ nothing           │     rke ┴ Bool: true         w ┴ nothing

The drawdown series of the path below is [0, -0.25, -0.1875, -0.3125, 0]. The last return lifts the cumulative return to a new peak. A weight of four on that period moves the mean towards zero.

julia> x = [0.125, -0.25, 0.0625, -0.125, 0.375];julia> AverageDrawdown()(x)0.15julia> AverageDrawdown(; w = pweights([1.0, 1.0, 1.0, 1.0, 4.0]))(x)0.09375

Related

References

  • [200] A. Chekhlov, S. Uryasev and M. Zabarankin. Drawdown measure in portfolio optimization. International Journal of Theoretical and Applied Finance 8, 13–58 (2005). Section 3.1, Definition 3.2, Equation 3.4.
source
PortfolioOptimisers.RelativeAverageDrawdown — Type
struct RelativeAverageDrawdown{__T_settings, __T_w} <: HierarchicalRiskMeasure

Measures the Relative Average Drawdown, the mean depth of the compounded drawdown over the sample.

The drawdown series is the one of relative_drawdown_vec: the wealth compounds the returns, and its running peak starts at $C_0 = 1$. Each drawdown is thus a fraction of the peak wealth. AverageDrawdown takes the same mean of the uncompounded series. The compounded wealth is a product of linear functions of the weights, so the library states no JuMP formulation of the measure, and it is a HierarchicalRiskMeasure.

Mathematical definition

\[\begin{align} \mathrm{RADD}(\boldsymbol{x}) &= -\frac{1}{T} \sum_{t=1}^{T} rd_t\,. \end{align}\]

Where:

  • $\mathrm{RADD}(\boldsymbol{x})$: Relative average drawdown.
  • $\boldsymbol{x}$: Portfolio returns vector $T \times 1$.
  • $rd_t \leq 0$: Relative drawdown at period $t$. relative_drawdown_vec states the series.
  • $T$: Number of observations.

With observation weights, the measure takes the weighted mean, as AverageDrawdown states, with $rd_t$ in place of $d_t$.

Section 3 of [200] defines the drawdown of the uncompounded cumulative return only. It names the relative drawdown and states that it lacks the properties of the absolute drawdown, but it defines no measure on it. The mean of the relative drawdown series is the library's extension of that work.

Algorithm

  1. Compute the relative drawdown series with relative_drawdown_vec.
  2. Resolve the observation weights with checked_observation_weights.
  3. Return average_drawdown of the series and the weights.

Fields

  • settings: Risk measure settings.
  • w: Optional observation weights vector observations × 1, or a concrete subtype of DynamicAbstractWeights. If nothing, the computation is unweighted.

Constructors

RelativeAverageDrawdown(;    settings::HierarchicalRiskMeasureSettings = HierarchicalRiskMeasureSettings(),    w::Option{<:ObsWeights} = nothing) -> RelativeAverageDrawdown

Keywords correspond to the struct's fields.

Validation

Propagated parameters

factory passes its arguments on to these @fprop fields:

Observation weight parameters

obs_weights_view indexes these fields to the selected observations:

Functor

(r::RelativeAverageDrawdown)(x::VecNum)

Computes the Relative Average Drawdown of a portfolio returns vector x.

Arguments

  • x::VecNum: Portfolio returns vector.

Examples

julia> RelativeAverageDrawdown()RelativeAverageDrawdown  settings ┼ HierarchicalRiskMeasureSettings           │   scale ┴ Float64: 1.0         w ┴ nothing

On the path of AverageDrawdown, the relative drawdown series is [0, -0.25, -0.203125, -0.302734375, -0.041259765625]. The compounded wealth does not reach a new peak at the last return, so the mean is larger than the 0.15 of the uncompounded series.

julia> x = [0.125, -0.25, 0.0625, -0.125, 0.375];julia> RelativeAverageDrawdown()(x)0.159423828125

Related

References

  • [200] A. Chekhlov, S. Uryasev and M. Zabarankin. Drawdown measure in portfolio optimization. International Journal of Theoretical and Applied Finance 8, 13–58 (2005). Section 3, Equation 3.2.
source

References

[200]
A. Chekhlov, S. Uryasev and M. Zabarankin. Drawdown measure in portfolio optimization. International Journal of Theoretical and Applied Finance 8, 13–58 (2005).