请求帮编个日内策略,以开盘一小时,最高价为A点,最低价为B点,向上突破A做多,B点+1跳止损, 如果先向下突破B则做空,A点+1跳 止损
资金使用使用量60%
感谢了
//以5分钟周期为例
INPUT:N(12,1,300,1);//N表示周期数。根据 N当前周期=1小时 来计算N数值。
A:VALUEWHEN(TODAYBAR=N,HHV(H,TODAYBAR));
B:VALUEWHEN(TODAYBAR=N,llv(l,TODAYBAR));
ktcd:cross(c,a);
kkcd:cross(b,c);
ptcd:c<b+1*MINDIFF;
pkcd:c>a+1*MINDIFF;
sell(ptcd,holding,market);
sellshort(pkcd,holding,market);
buy(ktcd and holding=0 and TODAYBAR>N,60%,market);
buyshort(kkcd and holding=0 and TODAYBAR>N,60%,market);