Utilities / Reference
alerta.str.substring
TradingView-compatible spelling: str.substring, runs without warnings
Returns a substring from begin to end.
alerta.str.substring(source, begin, end) → series stringParameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
source | series string | Yes | — | The string. |
begin | series int | Yes | — | Start index. |
end | series int | No | — | End index (exclusive). |
Returns
series stringExample
alerta.str.substring
indicator("Ticker prefix")prefix = str.substring(syminfo.tickerid, 0, 3)if barstate.islast label.new(bar_index, high, prefix)Names and aliases
Guides and navigation are localized. Built-in reference descriptions and code examples are maintained in English.