|
WU Trading Library 0.2.0
A backtesting and trading strategy library
|
Maximum Drawdown - tracks the largest peak-to-trough decline. More...
#include <indicators.h>
Data Fields | |
| double(* | update )(struct WU_MaxDrawdown_ *self, double portfolio_value) |
| void(* | delete )(struct WU_MaxDrawdown_ *self) |
| double | value |
| double | peak |
Maximum Drawdown - tracks the largest peak-to-trough decline.
Updates with portfolio values and returns the drawdown as a negative percentage. Calculated as (current_value - peak) / peak when current is below peak.
Definition at line 223 of file indicators.h.
| void(* WU_MaxDrawdown::delete) (struct WU_MaxDrawdown_ *self) |
Definition at line 225 of file indicators.h.
| double WU_MaxDrawdown::peak |
Definition at line 227 of file indicators.h.
| double(* WU_MaxDrawdown::update) (struct WU_MaxDrawdown_ *self, double portfolio_value) |
Definition at line 224 of file indicators.h.
| double WU_MaxDrawdown::value |
Definition at line 226 of file indicators.h.