软件名称:[B]期货FUTURES[/B]
软件类型:国产软件
运行环境:Win9X/Win2000/WinXP/Win2003/Win7/
软件语言:简体中文
授权方式:免费版
软件大小:0 Bytes
官方主页:Home Page
更新时间:2016-12-24 00:57:24
软件简介:
期货FUTURES
ret = 0; // 0:不确定状态; (0,100): 抄底;(100,x):修正,非抄底; (-100,0): 逃顶;(x,-100):修正,非抄底;
/***********different ******/
N=0;
C0 = SZZS_C0();
C1 = SZZS_C1();
C2 = SZZS_C2();
C3 = SZZS_C3();
C4 = SZZS_C4();
/**************common below (2016/6/23 - v1) *******************/
{
Open_N = REF(OPEN,N); //当天开盘价
Close_N = REF(CLOSE,N); //当天收盘价
High_N = REF(HIGH,N); //当天最高价
Low_N = REF(LOW,N); //当天最低价
Close_N1 = REF(CLOSE,N+1); //往前N+1个交易日收盘价
Close_N2 = REF(CLOSE,N+2); //往前N+2个交易日收盘价
Close_N3 = REF(CLOSE,N+3); //往前N+3个交易日收盘价
Close_N4 = REF(CLOSE,N+4); //往前N+3个交易日收盘价
Close_N5 = REF(CLOSE,N+5);
Open_N1 = REF(OPEN,N+1); //往前N+1天开盘价
Open_N2 = REF(OPEN,N+2); //往前N+2天开盘价
Open_N3 = REF(OPEN,N+3); //往前N+3天开盘价
Open_N4 = REF(OPEN,N+4); //往前N+4天开盘价
Low_N1 = REF(LOW,N+1); //往前N+1天最低价
Low_N2 = REF(LOW,N+2); //往前N+2天最低价
Low_N3 = REF(LOW,N+3); //往前N+3天最低价
Low_N4 = REF(LOW,N+4); //往前N+4天最低价
//买入信号
NoRiseDown = NOT((HIGH_N-CLOSE_N)/CLOSE_N1>0.02 AND Close_N/Close_N1<1.04);
IF(Close_N>Open_N AND Close_N>MA(Close_N,5) AND NoRiseDown AND CLOSE_N/CLOSE_N1>1.017)
ret=51;
ELSE IF (Close_N>Open_N AND NoRiseDown AND CLOSE_N/CLOSE_N1>1.017 AND MA(CLOSE_N,5)>MA(CLOSE_N,10))
ret=52;
IF (Close_N>Open_N AND Close_N>MA(Close_N,5) )
{
//大涨1.2%或者以上,75%涨
IF (Close_N/Close_N1>1.005 AND CODE != 'USDCNH' )
ret = 1;
ELSE IF (Close_N/Close_N1>1.002 AND CODE == 'USDCNH' )
RET=1;
//连续2次涨1%或者以上
ELSE IF (Close_N/CLOSE_N1>1.002 AND CLOSE_N1/CLOSE_N2>1.002 )
ret = 2;
//连红5日,最近4日不能大跌2%, 最近2天不能连续跌1%
ELSE IF(C0 AND C1 AND C2 AND C3 AND C4 AND COUNT(CLOSE_N1/CLOSE_N2>=0.995,4)==4 AND ( CLOSE_N1/CLOSE_N2>0.995 OR CLOSE_N2/CLOSE_N3>0.995))
ret = 3;
//红柱+ 1%或以上涨幅,前1日不能跌幅超过2%
ELSE IF (C0 AND CLOSE_N/CLOSE_N1>1.002 AND CLOSE_N1/CLOSE_N2>=0.995)
ret = 4;
}
//卖出信号
ELSE IF ( Close_N<MA(Close_N,5) AND CLOSE_N<OPEN_N) //破5日线,收阴
// AND ( Close_N<MA(Close_N,20) OR ( Close_N==Low_N) OR (Close_N>MA(Close_N,20) AND Close_N>MA(Close_N,20)*1.04)) ) // 破20日线 或者高于20日线的4% ,或当天最低
{
//count不起作用
i=0;
IF(CLOSE_N1<OPEN_N1)
i=i+1;
IF(CLOSE_N2<OPEN_N2)
i=i+1;
IF(CLOSE_N3<OPEN_N3)
i=i+1;
IF(CLOSE_N4<OPEN_N4)
i=i+1;
//
IF (CLOSE_N/CLOSE_N1<0.995 AND CODE != 'USDCNH')
ret = -1;
ELSE IF (CLOSE_N/CLOSE_N1<0.998 AND CODE == 'USDCNH')
ret = -1;
//连续2次跌幅超过1%
ELSE IF (CLOSE_N/CLOSE_N1<0.998 AND CLOSE_N1/CLOSE_N2<0.998 )
ret = -2;
//连绿5日,最近4日不能大涨1.7%或者以上,最近2天存在跌幅超过1%
ELSE IF (C0==0 AND C1==0 AND C2==0 AND C3==0 AND C4==0 AND COUNT(CLOSE_N1/CLOSE_N2 <= 1.005,4)==4 AND ( CLOSE_N1/CLOSE_N2 < 0.998 OR CLOSE_N2/CLOSE_N3 <0.998) )
ret = -3;
//绿柱,前1日不能大涨1.7%或者以上
ELSE IF (C0==0 AND CLOSE_N1/CLOSE_N2 <= 1.005 AND CODE != 'USDCNH' )
ret = -4;
ELSE IF (C0==0 AND CLOSE_N1/CLOSE_N2 <= 1.002 AND CODE == 'USDCNH' )
ret = -4;
//最近5日至少3阴线
// ELSE IF (COUNT(CLOSE_N1<OPEN_
[url=http://www.70822.com/soft/sort013/sort036/down-106384.html]期货FUTURES[/url]