MID : MA(CLOSE,26);
UPPER: MID + 2*STD(CLOSE,26);
LOWER: MID - 2*STD(CLOSE,26);
以上是金字塔自带的布林带公式 想把它改成 突破UPPER就开多 突破LOWER就开空 怎么编写,麻烦会的人帮个忙!谢谢!平仓就是回调到MID这条线 谢谢!
MID : MA(CLOSE,26);
UPPER: MID + 2*STD(CLOSE,26);
LOWER: MID - 2*STD(CLOSE,26);
if cross(c,upper) then buy(holding=0,1,market);
if cross(lower,c) then buyshort(holding=0,1,market);
if ref(c>mid,1) and c<mid then sell(1,0,market);
if ref(c<mid,1) and c>mid then sellshort(1,0,market);