设为首页收藏本站

 找回密码
 注册
查看: 1932|回复: 0
打印 上一主题 下一主题

老师麻烦帮编一个简单的程序 [复制链接]

Rank: 2

精华
0
UID
227668
积分
66
帖子
53
主题
5
阅读权限
30
注册时间
2016-1-30
最后登录
2023-3-7
1#
发表于 2016-3-14 09:29:20 |显示全部楼层
Params
        Numeric N1(5);
        Numeric N2(60);
      
Vars
        NumericSeries MA1;
        NumericSeries MA2;
        Numeric MinPoint;
        Numeric  myEntryPrice;
       Bool con1(False);
       Bool con2(False);
Begin
        MA1=AvregeFC(Close,N1);
        MA2=AvregeFC(Close,N2);
        MinPoint=MinMove*PriceScale;
        con1= Crossover(MA1[1]),MA2[1]);
        con2=H>=myEntryPrice+40* MinPoint  OR   L<=myEntryPrice-20* MinPoint;
        If(MarketPosition=0 AND con1=ture)
          {
            myEntryPrice=Open;
            BUY(0,myEntryPrice);
           }
        If(MarketPosition=1 AND con2=ture)Sell(0,0);
End
你试试

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

bottom

静态版|手机版|联系我们|交易开拓者 ( 粤ICP备07044698   

GMT+8, 2024-5-19 10:49

Powered by Discuz! X2 LicensedChrome插件扩展

© 2011-2012 交易开拓者 Inc.

回顶部