- UID
- 33654
- 帖子
- 1000
- 积分
- 188
- 阅读权限
- 20
- 注册时间
- 2006-6-12
- 最后登录
- 1970-1-1
- 在线时间
- 0 小时
|
ma1:=ma(close,5); // 5日平均收盘价
ma2:=ma(close,10); // 10日平均收盘价
e:= close>=ref(high,1) and close>=ref(high,2) and close>=ref(high,3) and close>=ref(high,4) and close>=ref(high,5) and close>=ref(high,6) and close>=ref(high,7) and close>=ref(high,8) and close>=ref(high,9) and close>=ref(high,10);
e赋值为: 当日收盘价要大于前10的最高价(true or false)
x:= count(cross(ma1,ma2),5)>=1;
x赋值为:5日平均线与10日平均线的金叉次数要大于1
buy:ma1>=ref(ma1,1) and ma2>=ref(ma2,1) and e and x;
如果e满足,x满足,并且5日均线上升,10日均线上升,则买入
sell:ma1<=ref(ma1,1) and ma2<=ref(ma2,1) and close<=ma1;
如果5日均线下降,10日均线下降 并且 收盘价小于5日均线,卖出
全部是从价格的角度考虑的,不是很准确,很容易受庄家的欺骗啊...
一定要结合量和筹码分布来考虑趋势.... |
|