Hi Folks
Anyone that can convert this pinescript from trading view for this simple strategy of entry on bar 2 and exit on other 2nd bar, for both long and short.
Thanks to anyone who can master coding for me, Margaret
C below the strategy code pasted
//@version=4
strategy(“BarUpDn Strategy”, overlay=true, default_qty_type = strategy.percent_of_equity, default_qty_value = 10)
maxIdLossPcnt = input(1, “Max Intraday Loss(%)”, type=input.float)
strategy.risk.max_intraday_loss(maxIdLossPcnt, strategy.percent_of_equity)
if (close > open and open > close[1])
strategy.entry(“BarUp”, strategy.long)
if (close < open and open < close[1])
strategy.entry(“BarDn”, strategy.short)
//plot(strategy.equity, title=”equity”, color=color.red, linewidth=2, style=plot.style_areabr)