//@version=5
indicator('Test Script', overlay=true)
Timeframe = input.timeframe('60')
i_T26 = input.symbol('NYSE:DINO')
f_strategy() =>
test = close > open*1.001 and barstate.isconfirmed ? 1 : close < open*0.999 and barstate.isconfirmed ? -1 : 0
f_screener(_ticker) =>
message = ''
[signal, _tickerClose] = request.security(_ticker, Timeframe, [f_strategy(), close])
if signal == 1
message := 'Go Long ' + _ticker + '@' + str.tostring(_tickerClose)
else if signal == -1
message := 'Go Short ' + _ticker + '@' + str.tostring(_tickerClose)
if signal == 1 or signal == -1
alert(message, alert.freq_once_per_bar_close)
signal
t26_signal = f_screener(i_T26)
plotshape(t26_signal, title='Alert', style=shape.triangleup, location=location.belowbar,
color=color.yellow, size=size.large)
plotshape(f_strategy()==-1 or f_strategy()==1, title='debug', style=shape.diamond,
location=location.belowbar, color=color.orange, size=size.large)