This code cannot be compiled or used in other pairs, it only works in BTC!!!
What should I do if I want to use it in other pairs?
( when I use this strategy on other pairs, I see a alarm notification in front of the indicator. If you hover your mouse pointer over this warning sign, you will notice a footnote that warns you that this indicator is not working properly and the information is not processed properly. (please look at to the second picture) ibb.co/zmCCDrm )
And how do I write a warning for that?
//@version=2
// simple cross of daily candle close
//
strategy("DailyCandleCross", shorttitle="DCC", overlay=true, calc_on_order_fills= true, calc_on_every_tick=true, default_qty_type=strategy.percent_of_equity, default_qty_value=75, pyramiding=0)
A=security(tickerid, 'D', close)
B=security(tickerid, 'D', close[1])
C=A>B
if(C)
strategy.entry("Long", strategy.long)
if(not C)
strategy.entry("Short", strategy.short)
Kind regards.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…