- 精华
- 0
- 在线时间
- 72 小时
- UID
- 166204
- 积分
- 102
- 帖子
- 89
- 阅读权限
- 30
- 注册时间
- 2013-1-24
- 最后登录
- 2022-3-28
- 精华
- 0
- UID
- 166204
- 积分
- 102
- 帖子
- 89
- 主题
- 12
- 阅读权限
- 30
- 注册时间
- 2013-1-24
- 最后登录
- 2022-3-28
|
Params
Numeric Lenth(60);
Numeric closeTime(14.45);
Vars
NumericSeries ma60;
Begin
ma60=Average(close,Lenth);
PlotNumeric("ma60",ma60,ma60,yellow);
If(MarketPosition<>1 && close[1]>ma60[1] && Time<closeTime/100)
{
Buy(0,open);
}
If(MarketPosition<>-1 && close[1]<ma60[1] && Time<closeTime/100)
{
SellShort(0,open);
}
If(MarketPosition!=0 && Time>=closeTime/100)
{
Sell(0,open);
BuyToCover(0,open);
}
End
|
|