求個資金平倉模塊 [金字塔]
- 咨詢內容:
比如100萬,虧10萬全部平倉或1000萬虧個20萬強平。后臺下單,高手寫個吧
- 金字塔客服:
if date<>ref(date,1) then extgbdataset('asset',tasset);
if todaybar>1 and extgbdata('asset')<=1000000 and extgbdata('asset')-tasset>100000 then tsell(1,0,mkt);//用全局變量記錄每天開市時的資金,然后判斷當前k線是否有虧損超過10萬,超過就平倉
1000萬資金虧20萬的同理,只要改第二句里面的100萬和10萬
[此貼子已經被作者于2013/11/20 10:50:52編輯過] - 用戶回復:
這個太復雜了,這樣行不if taconut2(6,'')<910000 and tholding2<>0 then beginttell(1,0,'');tshortell(1,0,'');endif taconut2(6,'')<910000 and tholding2=0 then exit;
- 網友回復:
也行,這個看自己的需求
有思路,想編寫各種指標公式,程序化交易模型,選股公式,預警公式的朋友
可聯系技術人員 QQ: 1145508240 進行 有償 編寫!(不貴!點擊查看價格!)
相關文章
-
沒有相關內容