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

【跟風發套系統】道氏理論系統分享 [開拓者 TB]

  • 咨詢內容: 跟穿堂風一個群的 平時喜歡琢磨點系統 我看流氓風分享了好幾套系統了 我也跟風發一個吧~
    道氏理論大家應該都很熟悉
    不太清楚的同志請自己搜索下 這個東西是套很經典的系統
    因為我是做日內的 所以寫成了日內交易 有興趣的朋友可以改成中長線的系統
    代碼如下
    1. //------------------------------------------------------------------------
    2. // 簡稱: D1
    3. // 名稱: 道氏理論
    4. // 類別: 交易指令
    5. // 類型: 多頭建倉
    6. // 輸出:
    7. //------------------------------------------------------------------------

    8. Params
    9.         Numeric ATime(918);
    10.         Numeric CTime(1510);
    11.         Numeric Lot(1);
    12.         Numeric MoneyLoss(0.6);
    13.         Numeric BarCross(1);
    14.         Numeric Length(5);
    15.        
    16. Vars
    17.         Numeric bTime(0);
    18.         Numeric MyClose(0);
    19.         Numeric MyDiff(0);
    20.         NumericSeries estP(0);
    21.         NumericSeries ExitP(0);
    22.         NumericSeries Position(0);
    23.         NumericSeries est(0);
    24.         NumericSeries est1(0);
    25.         NumericSeries est2(0);
    26.         NumericSeries est3(0);
    27.        
    28.         Bool bTimeCon;
    29.         Bool BarUpCon;
    30.         Bool BarDownCon;
    31.         Bool BarExitCon;
    32.         Bool LongOpenCon;
    33.         Bool ShortOpenCon;
    34.         Bool LongExitCon;
    35.         Bool ShortExitCon;
    36.        
    37. Begin
    38.        
    39.         If (Date != Date[1])
    40.                 {
    41.                         est = Open;
    42.                         est1 = Open;
    43.                         est2 = Open;
    44.                         est3 = Open;
    45.                         estP = 0;
    46.                         ExitP = 0;
    47.                         Position = 0;
    48.                         MyClose = Open;
    49.                 }
    50.         Else
    51.                 {
    52.                         est = est[1];
    53.                         est1 = est1[1];
    54.                         est2 = est2[1];
    55.                         est3 = est3[1];
    56.                         estP = estP[1];
    57.                         ExitP = ExitP[1];
    58.                         Position = Position[1];
    59.                         If(Length != 0) MyClose = Average(Close[1],Length);
    60.                         Else MyClose = Close[1];
    61.                 }
    62.                
    63.         MyDiff = MyClose * BarCross / 1000;
    64.        
    65.         bTime = IntPart(Time*10000);
    66.         bTimeCon = (bTime > ATime) And (bTime < CTime);
    67.        
    68.         If((MyClose < est And MyClose < est1) Or (MyClose > est And MyClose > est1)) est = MyClose;
    69.         If(((MyClose - est) > MyDiff And est < est1) Or ((est - MyClose) > MyDiff And est > est1))
    70.                 {
    71.                         est3 = est2;
    72.                         est2 = est1;
    73.                         est1 = est;
    74.                         est = MyClose;
    75.                 }
    76.                
    77.         If(Position > 0 And High > estP) estP = High;
    78.         If(Position < 0 And Low < estP) estP = Low;
    79.         If(Position > 0) ExitP = estP * (100 - MoneyLoss) / 100;
    80.         If(Position < 0) ExitP = estP * (100 + MoneyLoss) / 100;
    81.        
    82.         If(bTime >= CTime)
    83.         {
    84.                 If (Position > 0)
    85.                         Sell(lot,Open);
    86.                 Else
    87.                         BuyToCover(lot,Open);
    88.         }
    89.          
    90.         If(bTimeCon)
    91.         {
    92.                 If (Position == 0)
    93.                 {
    94.                         If(est3 < est1 And (est2 / 2000 + est2) <= est And est3 < est2)
    95.                         {
    96.                                 Buy(lot,Open);
    97.                                 Position = lot;
    98.                                 estP = Open;
    99.                                 ExitP = estP * (100 - MoneyLoss) / 100;
    100.                                 Commentary("LongOpen");
    101.                                
    102.                         }
    103.                          
    104.                         Else If(est3 > est1 And (est2 - est2 / 2000) >= est And est3 > est2)
    105.                         {
    106.                                 SellShort(lot,Open);
    107.                                 Position = lot * -1;
    108.                                 estP = Open;
    109.                                 ExitP = estP * (100 + MoneyLoss) / 100;
    110.                                 Commentary("ShortOpen");
    111.                         }
    112.                 }
    113.                
    114.                 Else
    115.                
    116.                 {
    117.                         If(Position > 0 And est3 > est1)
    118.                         {
    119.                                 Sell(lot,Open);
    120.                                 Position = 0;
    121.                                 Commentary("LongExit1");
    122.                         }
    123.                        
    124.                         Else If(Position < 0 And est3 < est1)
    125.                         {
    126.                                 BuyToCover(lot,Open);
    127.                                 Position = 0;
    128.                                 Commentary("ShortExit1");
    129.                         }
    130.                        
    131.                         Else If(Position > 0 And Open < ExitP)
    132.                         {
    133.                                 Sell(lot,Open);
    134.                                 Position = 0;
    135.                                 Commentary("LongExit2");
    136.                         }
    137.                        
    138.                         Else If(Position < 0 And Open > ExitP)
    139.                         {
    140.                                 BuyToCover(lot,Open);
    141.                                 Position = 0;
    142.                                 Commentary("ShortExit2");
    143.                         }
    144.                 }
    145.         }
    146.        
    147.         Commentary("Position = "+Text(Position));
    148.         Commentary("ExitP = "+Text(ExitP));
    149. End

    150. //------------------------------------------------------------------------
    151. // 編譯版本        GS2004.06.12
    152. // 用戶版本        2011/05/03 13:21
    153. // 版權所有        illidanyl
    154. // 更改聲明        TradeBlazer Software保留對TradeBlazer平臺
    155. //                        每一版本的TrabeBlazer公式修改和重寫的權利
    156. //------------------------------------------------------------------------

     

  • TB技術人員: 中間有些資金控制的東西 不修改任何參數的日內結果如下 大家圖個樂吧~
    11.jpg (109.97 KB, 下載次數: 8) 2011-7-26 17:08:48 上傳 下載次數: 8

     

  • TB客服: 快把壓箱底的交出來

     

  • 網友回復: 我的測試結果怎么和版主的不一樣?

     

  • 網友回復:
    快把壓箱底的交出來
    穿堂風 發表于 2011-7-26 17:34



        才不要 -v-

 

如果以上指標公式不適用于您常用的行情軟件

或者您想改編成選股公式,以便快速選出某種形態個股的話,

可以聯系我們相關技術人員 QQ: 262069696  點擊在線交流進行 有償 改編!

 


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

相關文章

    指定的模型還沒有相關內容!
主站蜘蛛池模板: 亚洲精品成人网站在线观看| 国产成人综合久久精品免费| 三级黄色片在线观看| 亚洲影视自拍揄拍愉拍| 日韩av第一页在线播放| 亚洲日韩一页精品发布| 色播影院性播免费看| 国产欧美va欧美va香蕉在线观看| 三大高傲校花被调教成好文| 日韩欧美中文字幕在线视频| 免费a级毛片18以上观看精品| 91香蕉视频导航| 天天做天天爱天天综合网2021| 中文精品久久久久国产网址| 日韩午夜伦y4480私人影院| 亚洲中文字幕日产乱码高清app| 欧美高清性色生活片免费观看| 俺去俺也在线www色官网| 国产乱子精品免费视观看片| 国产综合久久久久久| 三上悠亚中文字幕在线播放| 日本成人不卡视频| 久草视频精品在线| 激情图片在线视频| 国产丰满肥熟在线观看| 国产v亚洲v天堂a无| 国产福利在线观看极品美女| 2021国产麻豆剧传媒官网| 国语自产精品视频在线看| 中文字幕在线观看免费| 日本大片免aaa费观看视频| 久青草国产免费观看| 欧美一级专区免费大片| 伊人久久大香线蕉无码| 这里只有精品视频在线| 国产成人亚洲精品大帝| 99在线精品视频| 新版天堂资源在线官网8| 久久人人爽人人爽人人片AV高清| 日韩大片高清播放器| 久久精品这里有|