[原創(chuàng)]移動止損后臺交易模板 [金字塔]
- 咨詢內(nèi)容:
以下內(nèi)容為程序代碼:
1 input:stopnum(20,5,50,5);
2 runmode:1;
3
4 if tholding=0 then begin
5 extgbdataset('stopprice',low-stopnum*mindiff);
6 tbuy(1,1,lmt,close);
7 end;
8
9 if tholding>0 then begin
10 if low-stopnum*mindiff>extgbdata('stopprice') then
11 extgbdataset('stopprice',low-stopnum*mindiff);
12
13 if low<=extgbdata('stopprice') then begin
14 tsell(1,tholding,lmt,extgbdata('stopprice')),orderqueue;
15 tbuyshort(1,1,lmt,extgbdata('stopprice')),orderqueue;
16 end;
17 end;
18
19 if tholding<0 then begin
20 if high+stopnum*mindiff<extgbdata('stopprice') then
21 extgbdataset('stopprice',high+stopnum*mindiff);
22
23 if high>=extgbdata('stopprice') then begin
24 tsellshort(1,tholding,lmt,extgbdata('stopprice')),orderqueue;
25 tbuy(1,1,lmt,extgbdata('stopprice')),orderqueue;
26 end;
27 end;
28 - 金字塔客服:
通不過
- 用戶回復:
將代碼前面序號去掉
- 網(wǎng)友回復:
學習了
- 網(wǎng)友回復: ...一下就獎勵5個金幣。。真好啊。
- 上一篇:上海a股,日線顯示問題
- 下一篇:外匯數(shù)據(jù)出現(xiàn)錯誤
相關(guān)文章
-
沒有相關(guān)內(nèi)容