algotradelib 0.0.0.9000
C++ header-only library for algorithmic trading
Loading...
Searching...
No Matches
algotradelib::analytics::MaxDrawdown Struct Reference

The worst peak-to-trough decline of a level series, and where it happened. More...

#include <algotradelib/src/analytics/metrics.hpp>

Public Attributes

Scalar magnitude_ {0}
 The decline as a non-negative fraction of the peak (0.2 is 20% below it).
math::Index peak_row_ {-1}
 The row of the peak the decline fell from, or -1 if there is none.
math::Index trough_row_ {-1}
 The row of the low the decline reached, or -1 if there is none.

Detailed Description

The worst peak-to-trough decline of a level series, and where it happened.

Definition at line 62 of file metrics.hpp.

Member Data Documentation

◆ magnitude_

Scalar algotradelib::analytics::MaxDrawdown::magnitude_ {0}

The decline as a non-negative fraction of the peak (0.2 is 20% below it).

Definition at line 64 of file metrics.hpp.

Referenced by algotradelib::analytics::max_drawdown().

◆ peak_row_

math::Index algotradelib::analytics::MaxDrawdown::peak_row_ {-1}

The row of the peak the decline fell from, or -1 if there is none.

Definition at line 66 of file metrics.hpp.

Referenced by algotradelib::analytics::max_drawdown().

◆ trough_row_

math::Index algotradelib::analytics::MaxDrawdown::trough_row_ {-1}

The row of the low the decline reached, or -1 if there is none.

Definition at line 68 of file metrics.hpp.

Referenced by algotradelib::analytics::max_drawdown().


The documentation for this struct was generated from the following file: