: The timeframe of the requested data (e.g., "D" for daily, "60" for 60 minutes, "240" for 4-hour). An empty string "" refers to the current chart's timeframe.
Pine Script limits the number of unique security calls per script (usually 40). Correlation Traders: Fetch GOLD data while trading USDJPY . pine script v5 request.security function documentation
barmerge.gaps_off (Default): Returns data for every bar on the current chart. : The timeframe of the requested data (e
The ticker identifier (e.g., "NASDAQ:AAPL" or syminfo.tickerid ). "D" for daily
barmerge.lookahead_off (Default): Prevents future data leaking into the past (crucial for backtesting).
: The data or calculation you want to retrieve from the specified symbol/timeframe (e.g., close , hl2 , or a custom function call).
request.security(syminfo.tickerid, "60", close, lookahead = barmerge.lookahead_on)