SHORT:=12;
LONG:=26;
MID:=9;
DIF:=EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);
DEA:=EMA(DIF,MID);
MACD:=(DIF-DEA)*2;
N1:=6;
N2:=12;
N3:=24;
LC:=REF(CLOSE,1);
RSI1:=SMA(MAX(CLOSE-LC,0),N1,1)/SMA(ABS(CLOSE-LC),N1,1)*100;
RSI2:=SMA(MAX(CLOSE-LC,0),N2,1)/SMA(ABS(CLOSE-LC),N2,1)*100;
RSI3:=SMA(MAX(CLOSE-LC,0),N3,1)/SMA(ABS(CLOSE-LC),N3,1)*100;
TJ1:=CROSS(DIF,DEA);
MA5:=MA(C,5);
TJ3:=CROSS(C,MA5);
TJ4:=C/REF(C,1)>=1.02;
TJ2:=CROSS(RSI1,RSI2);
S1:=IF(NAMELIKE('S'),0,1);
S2:=IF(NAMELIKE('*'),0,1);
QQ:=DYNAINFO(4)>0;
QT:=S1 AND S2 AND QQ ;
XG:TJ1 AND TJ2 AND TJ3 AND TJ4 AND QT;
九毛八公式解读
SHORT赋值:12 LONG赋值:26 MID赋值:9 DIF赋值:收盘价的SHORT日指数移动平均-收盘价的LONG日指数移动平均 DEA赋值:DIF的MID日指数移动平均 MACD赋值:(DIF-DEA)*2 N1赋值:6 N2赋值:12 N3赋值:24 LC赋值:1日前的收盘价 RSI1赋值:收盘价-LC和0的较大值的N1日[1日权重]移动平均/收盘价-LC的绝对值的N1日[1日权重]移动平均*100 RSI2赋值:收盘价-LC和0的较大值的N2日[1日权重]移动平均/收盘价-LC的绝对值的N2日[1日权重]移动平均*100 RSI3赋值:收盘价-LC和0的较大值的N3日[1日权重]移动平均/收盘价-LC的绝对值的N3日[1日权重]移动平均*100 TJ1赋值:DIF上穿DEA MA5赋值:收盘价的5日简单移动平均 TJ3赋值:收盘价上穿MA5 TJ4赋值:收盘价/1日前的收盘价>=1.02 TJ2赋值:RSI1上穿RSI2 S1赋值:如果模糊匹配品种名称,返回0,否则返回1 S2赋值:如果模糊匹配品种名称,返回0,否则返回1 QQ赋值:开盘价>0 QT赋值:S1 AND S2 AND QQ 输出XG:TJ1 AND TJ2 AND TJ3 AND TJ4 AND QT