Skip to content
AlertaChartAlertaScript / docs
AlertaScript / alerta.strategy.opentrades.max_runup
On this pageSignatureParametersReturnsExample

Strategy / Reference

alerta.strategy.opentrades.max_runup

TradingView-compatible spelling: strategy.opentrades.max_runup, runs without warnings

Returns max favorable excursion for an open trade.

alerta.strategy.opentrades.max_runup(trade_index) → float

Parameters

NameTypeRequiredDefaultDescription
trade_indexintYes—Open trade index.

Returns

float

Example

alerta.strategy.opentrades.max_runup
strategy("Open Runup", overlay=true)v = strategy.opentrades > 0 ? strategy.opentrades.max_runup(0) : 0plot(v, { pane: "oscillator" })

Names and aliases

Guides and navigation are localized. Built-in reference descriptions and code examples are maintained in English.

AlertaScript

No results found.

Search by name, alias, or keyword.