前根K陽線下根開多,前陰線下根開空。 [金字塔]
- 咨詢內容:
請教:前根K陽線下根開多,前陰線下根開空。我就是想測試下發單。
if ref(c,1)>ref(o,1) then
begin
sellshort(1,1,thisclose);
buy(1,1,MARKET);
endif ref(c,1)<ref(o,1) then
begin
sell(1,1,thisclose);
buyshort(1,1,market);
end
但實際執行時候,只能一直開多或一直開空,而不是根據前根陽或陰而變化,不明白是咋回事? - 金字塔客服:
您好,開平倉條件加上holding的限制。
if ref(c,1)>ref(o,1) then
begin
sellshort(holding<0,1,thisclose);
buy(holding=0,1,MARKET);
endif ref(c,1)<ref(o,1) then
begin
sell(holding>0,1,thisclose);
buyshort(holding=0,1,market);
end
有思路,想編寫各種指標公式,程序化交易模型,選股公式,預警公式的朋友
可聯系技術人員 QQ: 1145508240 進行 有償 編寫!(不貴!點擊查看價格!)
相關文章
-
沒有相關內容