Utilities / Reference
if
TradingView-compatible spelling: if, runs without warnings
Runs an indented block when its condition is true. An optional else branch handles the other case.
if close > open → language constructReturns
language constructExample
//@version=6indicator("Conditional block")if close > open log.info("Up bar")Names and aliases
Guides and navigation are localized. Built-in reference descriptions and code examples are maintained in English.