大伊人青草狠狠久久-大伊香蕉精品视频在线-大伊香蕉精品一区视频在线-大伊香蕉在线精品不卡视频-大伊香蕉在线精品视频75-大伊香蕉在线精品视频人碰人

您現在的位置:程序化交易>> 期貨公式>> (MC)multicharts>> MC知識>>正文內容

請問老師關于日內多次突破交易的問題 [MC]

  • MC用戶求助:

    關于swinghigh函數的用法,您可以先看一下帖子http://forums.icetech.com.cn/for ... &extra=page%3D1,在學習這個帖子的過程中遇到的問題可以直接在該帖子下方回帖。

    ?

    另外,關于您的這個策略需求,我簡單在您的代碼中加了幾行代碼,如下:

    input:btime(0930),etime(1445);

    var:thigh(0),tlow(0),mp(0);

    if date<>date[1] then begin

    ? ? mp=0;

    ? ? thigh=0;

    ? ? tlow=0;

    ? ?end;

    if time=btime then begin

    ? ? thigh=highd(0);

    ? ? tlow=lowd(0);

    ? ? end;

    mp=marketposition;

    if time>btime and time<etime then begin

    ? ? if mp=0 and close cross above thigh then begin

    ? ? ? ?buy ("b1")next bar at thigh stop;

    ? ? ? ? end;

    ? ? if mp=1 then sell("sp") next bar at tlow stop;

    ?

    ? ? if mp=0 and close cross under tlow then begin

    ? ? ? ? sellshort ("s1")next bar at tlow stop;

    ? ? ? ? end;

    ? ? if mp=-1 then buytocover("bp") next bar at thigh stop;

    //增加

    ? ? if mp=0 and mp[1]<>0 then begin

    ? ? ? ? ? ? thigh=highd(0);

    ? ? ? ? ? ? tlow=lowd(0);

    ? ? end;

    //增加

    {這個地方,是一個即時的代碼,也就是當前一根bar上持倉,而當根bar未持倉,那么重新賦值thigh和tlow,后續的進場會根據這兩個新的值進行進場和出場了}

    end;

    ?

  • MC回復討論一:

    關于swinghigh函數的用法,您可以先看一下帖子http://forums.icetech.com.cn/for ... &extra=page%3D1,在學習這個帖子的過程中遇到的問題可以直接在該帖子下方回帖。

    ?

    另外,關于您的這個策略需求,我簡單在您的代碼中加了幾行代碼,如下:

    input:btime(0930),etime(1445);

    var:thigh(0),tlow(0),mp(0);

    if date<>date[1] then begin

    ? ? mp=0;

    ? ? thigh=0;

    ? ? tlow=0;

    ? ?end;

    if time=btime then begin

    ? ? thigh=highd(0);

    ? ? tlow=lowd(0);

    ? ? end;

    mp=marketposition;

    if time>btime and time<etime then begin

    ? ? if mp=0 and close cross above thigh then begin

    ? ? ? ?buy ("b1")next bar at thigh stop;

    ? ? ? ? end;

    ? ? if mp=1 then sell("sp") next bar at tlow stop;

    ?

    ? ? if mp=0 and close cross under tlow then begin

    ? ? ? ? sellshort ("s1")next bar at tlow stop;

    ? ? ? ? end;

    ? ? if mp=-1 then buytocover("bp") next bar at thigh stop;

    //增加

    ? ? if mp=0 and mp[1]<>0 then begin

    ? ? ? ? ? ? thigh=highd(0);

    ? ? ? ? ? ? tlow=lowd(0);

    ? ? end;

    //增加

    {這個地方,是一個即時的代碼,也就是當前一根bar上持倉,而當根bar未持倉,那么重新賦值thigh和tlow,后續的進場會根據這兩個新的值進行進場和出場了}

    end;

 

有思路,想編寫各種指標公式,程序化交易模型,選股公式,預警公式的朋友

可聯系技術人員 QQ: 511411198  點擊這里給我發消息進行 有償 編寫!不貴!點擊查看價格!


【字體: 】【打印文章】【查看評論

相關文章

    沒有相關內容
主站蜘蛛池模板: 快射视频网 | 五月天婷亚洲天综合网精品偷 | 偷偷鲁影院手机在线观看 | 91视频夜色 | 欧美视频一区二区专区 | 亚洲成人性视频 | 日韩经典在线 | 日不卡在线 | www久久只有这里有精品 | 老司机观看精品一区二区 | 中国免费一级毛片 | 欧美综合精品 | 成人性毛片 | 在线观看欧洲成人免费视频 | 天天操天天射天天操 | 亚洲光棍天堂 | 久久亚洲美女久久久久 | 香蕉视频看片 | 久久99亚洲精品久久久久99 | 日韩视频免费一区二区三区 | 日韩一区二区超清视频 | 看真人视频一一级毛片 | 国产四虎| 色噜噜狠狠色综合免费视频 | 伊人色综合网一区二区三区 | 四虎国产精品永久在线播放 | 伊人午夜 | 99精品国产一区二区三区 | 国产精品久久久久aaaa | 国内视频一区二区 | 99视频在线免费看 | 九九色综合网 | 日韩中文字幕a | 久草免费在线观看 | 四虎影视在线看免费观看 | 奇米影视狠狠干 | 成人网影 | 婷婷国产偷v国产偷v亚洲 | 久久爱www成人 | 久久国产免费观看 | 深夜影院a |