期貨期權交流我自己寫的信號木有信號
作者:MC 來源:cxh99.com 發布時間:2016年03月24日
- 咨詢內容:
inputs:zhisune(200);
variables: mp(0),zhisun(0),ADX(0);
condition1 = Close > Open and High > High[1] ;
condition2 = Close > Open and High = High[1] and Low > Low[1];
condition3 = Close > Open and High < High[1] and Low > Low[1];
condition4 = Close < Open and High < High[1] ;
condition5 = Close < Open and High = High[1] and Low < Low[1];
condition6 = Close < Open and High > High[1] and Low < Low[1];
mp = marketposition;
zhisun = zhisune;
if ADX>20 then begin
if condition1 and condition2 and condition3 then
buytocover("Buy1") next bar at market;
end;
if ADX>20 then begin
if condition4 or condition5 or condition6 then
sellshort("Sell1") next bar at market;
end;
實在找不出哪里出問題 求指點
- MC技術部:
print(adx)看看, 該值看起來一直為0, 所以沒有滿足你的開倉條件