期貨期權(quán)交流為什么沒(méi)法加倉(cāng)
作者:MC 來(lái)源:cxh99.com 發(fā)布時(shí)間:2016年07月23日
- 咨詢內(nèi)容:
我寫(xiě)了以下的程序,想要加倉(cāng),結(jié)果圖上只有一個(gè)entry信號(hào),沒(méi)法加倉(cāng),請(qǐng)問(wèn)如何解決,很急
var: LTT( 0 ), Myfhigh( 0 ), Myflow( 0 ), Myshigh( 0 ), Myslow( 0 ), mp( 0 ), Myatr( 0 );
mp = marketposition;
condition1 =c>o and marketposition=0;
condition2 =c>o and c[1]>o[1];
condition3 = c>o and c[1]>o[1] and c[2]>o[2];
if condition1 then buy ("entry") next bar at market;
if condition2 then buy ("jiacang1") next bar at market;
if condition3 then buy ("jiacang2") next bar at market;