- 精华
- 0
- 在线时间
- 118 小时
- UID
- 212247
- 积分
- 128
- 帖子
- 83
- 阅读权限
- 40
- 注册时间
- 2015-6-28
- 最后登录
- 2019-11-15
- 精华
- 0
- UID
- 212247
- 积分
- 128
- 帖子
- 83
- 主题
- 23
- 阅读权限
- 40
- 注册时间
- 2015-6-28
- 最后登录
- 2019-11-15
|
Params
Vars
Numeric H10(0);
numeric L10(0);
numeric HH(0);
numeric LL(0);
Begin
If( time <=0.1000)
{
H10=Highest(h,barssincetoday+1);
L10=Lowest(l,barssincetoday+1);
SetGlobalVar(1,H10);
SetGlobalVar(2,L10);
}
If( time>=0.1000)
{
PlotNumeric("h10",getglobalvar(1));
PlotNumeric("l10",getglobalvar(2));
HH=getglobalvar(1);
LL=GetGlobalVar(2);
}
If(time>0.1000 and time<0.1455 )
{
if (MarketPosition==0 and close[1]>HH And close<HH)
SellShort(1,close);
if (marketposition==0 and close[1]<LL and close>LL)
Buy(1,close);
if (marketposition==-1 and close>HH ) BuyToCover(1,close);
if (marketposition==1 and close<LL ) Sell(1,close);
}
if(time>=0.1455 and marketposition!=0)
{BuyToCover(1,close);
Sell(1,close);};
end
|
|