- 精华
- 0
- 在线时间
- 44 小时
- UID
- 267738
- 积分
- 94
- 帖子
- 68
- 阅读权限
- 30
- 注册时间
- 2018-7-21
- 最后登录
- 2020-4-9
- 精华
- 0
- UID
- 267738
- 积分
- 94
- 帖子
- 68
- 主题
- 18
- 阅读权限
- 30
- 注册时间
- 2018-7-21
- 最后登录
- 2020-4-9
|
本帖最后由 ad434005 于 2018-10-20 22:10 编辑
if(MarketPosition==0)
{
if(High>high[1] and high>junxian ) buy(2,max(open,high[1]));//junxian为均线;
if(Low<low[1] and low<junxian ) SellShort(2,min(open,low[1]));
else if(MarketPosition==1 and BarsSinceEntry>1 )
{
While( high>high[1] and CurrentEntries<3)
{
if(zdfy>2000 and abs(currentcontracts)==2 )Buy(2,open);//zdfy为最大浮盈;
if(zdfy>4000 and abs(currentcontracts)==4) Buy(2,open);
}
While( low<low[1] and CurrentEntries>0)
{
if( zdfy<-100 and abs(currentcontracts)==2) sell(2,open);
if( zdfy<1000 and abs(currentcontracts)==4) sell(4,open);
if( zdfy<2000 and abs(currentcontracts)==6) sell(6,open);
}
}
} |
|